Merge pull request #2251 from nyanmisaka/master
add support for AMD AMF hardware encoding on Windows & Linux
This commit is contained in:
commit
4aa0b940e3
|
@ -2642,22 +2642,9 @@ namespace MediaBrowser.Controller.MediaEncoding
|
|||
else
|
||||
return "-hwaccel dxva2";
|
||||
}
|
||||
|
||||
switch (videoStream.Codec.ToLowerInvariant())
|
||||
else
|
||||
{
|
||||
case "avc":
|
||||
case "h264":
|
||||
if (_mediaEncoder.SupportsDecoder("h264_amf") && encodingOptions.HardwareDecodingCodecs.Contains("h264", StringComparer.OrdinalIgnoreCase))
|
||||
{
|
||||
return "-c:v h264_amf";
|
||||
}
|
||||
break;
|
||||
case "mpeg2video":
|
||||
if (_mediaEncoder.SupportsDecoder("hevc_amf") && encodingOptions.HardwareDecodingCodecs.Contains("mpeg2video", StringComparer.OrdinalIgnoreCase))
|
||||
{
|
||||
return "-c:v mpeg2_mmal";
|
||||
}
|
||||
break;
|
||||
return "-hwaccel vaapi";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -55,7 +55,9 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
|||
"h264_vaapi",
|
||||
"hevc_vaapi",
|
||||
"h264_v4l2m2m",
|
||||
"ac3"
|
||||
"ac3",
|
||||
"h264_amf",
|
||||
"hevc_amf"
|
||||
};
|
||||
|
||||
// Try and use the individual library versions to determine a FFmpeg version
|
||||
|
|
Loading…
Reference in New Issue
Block a user