summaryrefslogtreecommitdiffstats
path: root/video/decode
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2017-01-24 08:11:42 +0100
committerwm4 <wm4@nowhere>2017-01-24 08:11:42 +0100
commitb14fac9afa79e44d8b0323c6ddbef1557cdd0d8d (patch)
tree676e8e9ef45690491d827b553ec8cc29f49e84f3 /video/decode
parent6be58df8d14922bc1f4252f9f69ca9c0d74c331a (diff)
downloadmpv-b14fac9afa79e44d8b0323c6ddbef1557cdd0d8d.tar.bz2
mpv-b14fac9afa79e44d8b0323c6ddbef1557cdd0d8d.tar.xz
build: replace some FFmpeg API checks with version checks
The FFmpeg versions we support all have the APIs we were checking for. Only Libav missed them. Simplify this by explicitly checking for FFmpeg in the code, instead of trying to detect the presence of the API.
Diffstat (limited to 'video/decode')
-rw-r--r--video/decode/vd_lavc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/video/decode/vd_lavc.c b/video/decode/vd_lavc.c
index 19a6336f19..c4cfbc30d3 100644
--- a/video/decode/vd_lavc.c
+++ b/video/decode/vd_lavc.c
@@ -48,7 +48,7 @@
#include "video/csputils.h"
#include "video/sws_utils.h"
-#if HAVE_AVUTIL_MASTERING_METADATA
+#if LIBAVCODEC_VERSION_MICRO >= 100
#include <libavutil/mastering_display_metadata.h>
#endif
@@ -624,7 +624,7 @@ static void update_image_params(struct dec_video *vd, AVFrame *frame,
{
vd_ffmpeg_ctx *ctx = vd->priv;
-#if HAVE_AVUTIL_MASTERING_METADATA
+#if LIBAVCODEC_VERSION_MICRO >= 100
// Get the reference peak (for HDR) if available. This is cached into ctx
// when it's found, since it's not available on every frame (and seems to
// be only available for keyframes)