@ -233,6 +233,16 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
@@ -233,6 +233,16 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
@ -248,7 +258,8 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
@@ -248,7 +258,8 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
videoPath!=audioPath,// still image when paths are different
scanKind);
scanKind,
hasMultipleProfiles);
varvideoInputFile=newVideoInputFile(
videoPath,
@ -405,8 +416,6 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
@@ -405,8 +416,6 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
@ -652,6 +661,19 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
@@ -652,6 +661,19 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
returnresult;
}
privateasyncTask<bool>ProbeHasMultipleProfiles(
stringffmpegPath,
MediaItemmediaItem,
CancellationTokencancellationToken)
{
_logger.LogDebug("Will probe for h264 profile count");
@ -91,6 +91,14 @@ public class QsvPipelineBuilder : SoftwarePipelineBuilder
@@ -91,6 +91,14 @@ public class QsvPipelineBuilder : SoftwarePipelineBuilder
decodeCapability=FFmpegCapability.Software;
}
// QSV cannot always decode properly when *not* seeking, so check if software is needed
@ -181,6 +181,24 @@ public partial class LocalStatisticsProvider : ILocalStatisticsProvider
@@ -181,6 +181,24 @@ public partial class LocalStatisticsProvider : ILocalStatisticsProvider
returnOption<double>.None;
}
publicasyncTask<Option<int>>GetProfileCount(
stringffmpegPath,
MediaItemmediaItem,
CancellationTokencancellationToken)
{
try
{
stringfilePath=awaitPathForMediaItem(mediaItem);
returnawaitGetProfileCount(ffmpegPath,filePath);
}
catch(Exceptionex)
{
_logger.LogWarning(ex,"Failed to check profile count for media item {Id}",mediaItem.Id);
@ -336,6 +354,46 @@ public partial class LocalStatisticsProvider : ILocalStatisticsProvider
@@ -336,6 +354,46 @@ public partial class LocalStatisticsProvider : ILocalStatisticsProvider