mirror of
https://github.com/revenz/FileFlowsPlugins.git
synced 2026-02-14 19:29:15 -06:00
fixing pixel format issue
This commit is contained in:
@@ -197,7 +197,7 @@ public class FfmpegBuilderExecutor: FfmpegBuilderNode
|
||||
if (targetIs10Bit && video?.Stream?.Is10Bit == true)
|
||||
pxtFormat = "p010le";
|
||||
else if (targetIs10Bit == false && video?.Stream?.Is10Bit == false && video?.Stream?.Is12Bit == false)
|
||||
pxtFormat = "yuv420p";
|
||||
pxtFormat = "nv12";
|
||||
else if (targetIs10Bit)
|
||||
pxtFormat = string.Empty; // clear it, if we use a 8bit pixel format this will break the colours
|
||||
|
||||
@@ -296,8 +296,6 @@ public class FfmpegBuilderExecutor: FfmpegBuilderNode
|
||||
continue;
|
||||
}
|
||||
|
||||
if (hwOrig.Any(x => x.Contains("qsv")) && pixelFormat == "yuv420p")
|
||||
pixelFormat = "nv12";
|
||||
|
||||
var hw = hwOrig.Select(x => x.Replace("#FORMAT#", pixelFormat)).ToArray();
|
||||
|
||||
|
||||
@@ -461,7 +461,7 @@ public class VideoInfoHelper
|
||||
if(Regex.IsMatch(line, @"p(0)?10l(b)?e"))
|
||||
return "p010le";
|
||||
if(line.IndexOf("yuv420p", StringComparison.Ordinal) > 0)
|
||||
return "yuv420p";
|
||||
return "nv12"; // use nv12 instead of yuv420p
|
||||
// if (line.IndexOf("nv12", StringComparison.Ordinal) >= 0)
|
||||
// return "nv12";
|
||||
// if (line.IndexOf("yuv444p", StringComparison.Ordinal) >= 0)
|
||||
|
||||
Reference in New Issue
Block a user