[Cin] AMD's amf in ffmpeg

Terje J. Hanssen terjejhanssen at gmail.com
Thu Dec 12 01:11:32 CET 2024




Den 12.12.2024 00:46, skrev Andrew Randrianasulu via Cin:
> As Terje requested I looked up into amf compilation, _it seems_ it 
> just require headers at compilation stage BUT amdgpu-pro runtime for 
> any real use, and it goes via vulkan anyway ?
>
>
> https://ffmpeg.org/general.html#AMD-AMF_002fVCE
>


Some related sections I have extracted and collected, but not neccessary 
up to date:

AMD / Mesa
The Mesa VAAPI driver uses the UVD (Unified Video Decoder) and VCE 
(Video Coding Engine) hardware found in all recent AMD graphics cards 
and APUs.
https://trac.ffmpeg.org/wiki/Hardware/VAAPI#AMDMesa

And this reminded me about our interlace problematic:
Encoding and interlacing support in Mesa are incompatible because of the 
data layout in GPU memory. By default, frames are separated into fields 
and interlaced video is supported but encoding is not. Set the 
environment variable VAAPI_DISABLE_INTERLACE to 1 to be able to use the 
encoder (but without any interlaced video support).

AMD/VAAPI
https://trac.ffmpeg.org/wiki/HWAccelIntro#PlatformAPIAvailability
P Partial support (some devices / some features).

VAAPI
https://trac.ffmpeg.org/wiki/HWAccelIntro#VAAPI
Video Acceleration API (VAAPI) is a non-proprietary and royalty-free 
open source software library ("libva") and API specification, initially 
developed by Intel but can be used in combination with other devices.

It can be used to access the Quick Sync hardware in Intel GPUs (!?)and 
the UVD/VCE hardware in AMD GPUs. See VAAPI.

AMD UVD/VCE ¶
https://trac.ffmpeg.org/wiki/HWAccelIntro#AMDUVDVCE
AMD UVD is usable for decode via VDPAU and VAAPI in Mesa on Linux. VCE 
also has some initial support for encode via VAAPI, but should be 
considered experimental.

AMF is effectively supported by FFmpeg to significantly speed up video 
encoding, decoding, and transcoding via AMD GPUs.

AMD / Mesa
https://trac.ffmpeg.org/wiki/Hardware/VAAPI#AMDMesa
The Mesa VAAPI driver uses the UVD (Unified Video Decoder) and VCE 
(Video Coding Engine) hardware found in all recent AMD graphics cards 
and APUs.

i965 Driver
https://trac.ffmpeg.org/wiki/Hardware/QuickSync#i965vs.iHDDrivervs.libvpllibmfx
     Supports VAAPI
     i965 is packaged as standard in most Linux distributions.
     Runs on older and cheaper devices.
     Common API for applications which may also use AMD hardware with Mesa.
     Interoperable with standard APIs (EGL/OpenGL, OpenCL).



More information about the Cin mailing list