path: root/
diff options
authorwm4 <wm4@nowhere>2017-01-11 16:27:58 +0100
committerwm4 <wm4@nowhere>2017-01-11 16:34:18 +0100
commit2afef344fb76f534426c047a3d5077e761a2e00a (patch)
treead30baa2982f00f4cc11397104def8d4be5570d8 /
parentf4263922c7a251ac429aa0e023bbd81ac6888c54 (diff)
vaapi: support new libavcodec vaapi API
The old API is deprecated, and libavcodec prints a warning at runtime. The new API is a bit nicer and does many things for you, such as managing the underlying hwaccel decoder. libavutil also provides code for managing surfaces (we use their surface pool). The new code does not contain any code from the original MPlayer VAAPI patch (that was used as base for some of the vaapi code in mpv). Thus the new code is LGPL. The new API actually does not add any visible symbols, so the only way to detect it is a version check. Of course, the versions overlap between FFmpeg and Libav, which requires additional care. The new API did not get merged into FFmpeg yet, so there's no check for FFmpeg.
Diffstat (limited to '')
1 files changed, 2 insertions, 1 deletions
diff --git a/ b/
index 80e15fb9f4..8e3cb6aa8e 100644
--- a/
+++ b/
@@ -307,7 +307,8 @@ def build(ctx):
( "video/decode/dxva2.c", "d3d-hwaccel" ),
( "video/decode/d3d11va.c", "d3d-hwaccel" ),
( "video/decode/d3d.c", "win32" ),
- ( "video/decode/vaapi_old.c", "vaapi-hwaccel" ),
+ ( "video/decode/vaapi.c", "vaapi-hwaccel-new" ),
+ ( "video/decode/vaapi_old.c", "vaapi-hwaccel-old" ),
( "video/decode/vd_lavc.c" ),
( "video/decode/videotoolbox.c", "videotoolbox-hwaccel" ),
( "video/decode/vdpau.c", "vdpau-hwaccel" ),