|
|
|
@ -478,7 +478,9 @@ namespace MediaBrowser.Controller.MediaEncoding
|
|
|
|
|
if (!string.IsNullOrEmpty(videoDecoder) && videoDecoder.Contains("qsv"))
|
|
|
|
|
{
|
|
|
|
|
arg.Append("-hwaccel qsv ");
|
|
|
|
|
} else {
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
arg.Append("-init_hw_device qsv=hw -filter_hw_device hw ");
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -1591,7 +1593,9 @@ namespace MediaBrowser.Controller.MediaEncoding
|
|
|
|
|
if (string.Equals(outputVideoCodec, "h264_qsv", StringComparison.OrdinalIgnoreCase))
|
|
|
|
|
{
|
|
|
|
|
videoSizeParam += ",hwupload=extra_hw_frames=64";
|
|
|
|
|
} else {
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
videoSizeParam += ":force_original_aspect_ratio=decrease";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -1605,7 +1609,6 @@ namespace MediaBrowser.Controller.MediaEncoding
|
|
|
|
|
: state.SubtitleStream.Index;
|
|
|
|
|
|
|
|
|
|
var videoDecoder = GetHardwareAcceleratedVideoDecoder(state, options);
|
|
|
|
|
|
|
|
|
|
var retStr = " -filter_complex \"[{0}:{1}]{4}[sub];[0:{2}][sub]overlay{3}\"";
|
|
|
|
|
|
|
|
|
|
if (string.Equals(outputVideoCodec, "h264_qsv", StringComparison.OrdinalIgnoreCase))
|
|
|
|
@ -1613,7 +1616,9 @@ namespace MediaBrowser.Controller.MediaEncoding
|
|
|
|
|
if (!string.IsNullOrEmpty(videoDecoder) && videoDecoder.Contains("qsv"))
|
|
|
|
|
{
|
|
|
|
|
retStr = " -filter_complex \"[{0}:{1}]{4}[sub];[0:{2}][sub]overlay_qsv=x=(W-w)/2:y=(H-h)/2{3}\"";
|
|
|
|
|
} else {
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
retStr = " -filter_complex \"[{0}:{1}]{4}[sub];[0:{2}]hwupload=extra_hw_frames=64[v];[v][sub]overlay_qsv=x=(W-w)/2:y=(H-h)/2{3}\"";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -1707,7 +1712,9 @@ namespace MediaBrowser.Controller.MediaEncoding
|
|
|
|
|
vaapi_or_qsv,
|
|
|
|
|
outputWidth,
|
|
|
|
|
outputHeight));
|
|
|
|
|
} else {
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
filters.Add(string.Format(CultureInfo.InvariantCulture, "scale_{0}=format=nv12", vaapi_or_qsv));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|