Minor fixes

Former-commit-id: 06da927c7e
This commit is contained in:
Malte Rosenbjerg 2021-10-21 19:44:22 +02:00
parent 849eb3ce54
commit 2de12dd61d

View file

@ -116,12 +116,9 @@ private static (FFMpegArguments, Action<FFMpegArgumentOptions> outputOptions) Bu
{
captureTime ??= TimeSpan.FromSeconds(source.Duration.TotalSeconds / 3);
size = PrepareSnapshotSize(source, size);
if (streamIndex == null)
{
streamIndex = source.PrimaryVideoStream?.Index
?? source.VideoStreams.First()?.Index
?? 0;
}
streamIndex ??= source.PrimaryVideoStream?.Index
?? source.VideoStreams.FirstOrDefault()?.Index
?? 0;
return (FFMpegArguments
.FromFileInput(input, false, options => options