Merge branch 'master' into tonemap

This commit is contained in:
Nyanmisaka 2020-07-27 13:57:40 +08:00 committed by GitHub
commit df6b303da7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
30 changed files with 493 additions and 621 deletions

View file

@ -457,6 +457,7 @@ namespace MediaBrowser.Controller.MediaEncoding
var isNvencHevcDecoder = videoDecoder.IndexOf("hevc_cuvid", StringComparison.OrdinalIgnoreCase) != -1;
var isWindows = RuntimeInformation.IsOSPlatform(OSPlatform.Windows);
var isLinux = RuntimeInformation.IsOSPlatform(OSPlatform.Linux);
var isMacOS = RuntimeInformation.IsOSPlatform(OSPlatform.OSX);
if (!IsCopyCodec(outputVideoCodec))
{
@ -529,6 +530,11 @@ namespace MediaBrowser.Controller.MediaEncoding
.Append(' ')
.Append("-filter_hw_device ocl ");
}
if (state.IsVideoRequest
&& string.Equals(encodingOptions.HardwareAccelerationType, "videotoolbox", StringComparison.OrdinalIgnoreCase))
{
arg.Append("-hwaccel videotoolbox ");
}
}