From 398bfbe4c15e0459b0d13eea78e913ea75402c92 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sun, 8 Dec 2013 23:38:35 +0100 Subject: compat: add compatibility kludge for Libav 9 Libav 9 still uses the unprefixed PIX_FMT_... symbols, but they will probably be removed some time in the future. There are some other deprecations we have yet to take care of, but there are no clear replacements yet. --- compat/libav.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'compat') diff --git a/compat/libav.h b/compat/libav.h index ba5250b5f3..56876c1336 100644 --- a/compat/libav.h +++ b/compat/libav.h @@ -28,4 +28,16 @@ #define AV_CPU_FLAG_MMX2 AV_CPU_FLAG_MMXEXT #endif +// At least Libav 9 doesn't define the new symbols +#ifndef AV_PIX_FMT_FLAG_BE +#define AV_PIX_FMT_FLAG_BE PIX_FMT_BE +#define AV_PIX_FMT_FLAG_PAL PIX_FMT_PAL +#define AV_PIX_FMT_FLAG_BITSTREAM PIX_FMT_BITSTREAM +#define AV_PIX_FMT_FLAG_HWACCEL PIX_FMT_HWACCEL +#define AV_PIX_FMT_FLAG_PLANAR PIX_FMT_PLANAR +#define AV_PIX_FMT_FLAG_RGB PIX_FMT_RGB +#define AV_PIX_FMT_FLAG_PSEUDOPAL PIX_FMT_PSEUDOPAL +#define AV_PIX_FMT_FLAG_ALPHA PIX_FMT_ALPHA +#endif + #endif /* MPV_LIBAV_COMPAT_H */ -- cgit v1.2.3