allow clearing (omitting) video profile setting (#1706)

This commit is contained in:
Jason Dove
2024-05-05 19:23:26 -05:00
committed by GitHub
parent dc3578660f
commit ef6c8b0816
2 changed files with 4 additions and 3 deletions
@@ -449,7 +449,7 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
AudioFilter.None);
var videoFormat = GetVideoFormat(playbackSettings);
var desiredState = new FrameState(
playbackSettings.RealtimeOutput,
false,
@@ -998,7 +998,7 @@ public class FFmpegLibraryProcessService : IFFmpegProcessService
};
private static Option<string> GetVideoProfile(string videoFormat, string videoProfile) =>
(videoFormat, videoProfile.ToLowerInvariant()) switch
(videoFormat, (videoProfile ?? string.Empty).ToLowerInvariant()) switch
{
(VideoFormat.H264, VideoProfile.Main) => VideoProfile.Main,
(VideoFormat.H264, VideoProfile.High) => VideoProfile.High,