From 977116a0ca30351531c1fac482f149e7d7af6f53 Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Wed, 10 Oct 2012 22:21:57 +0300 Subject: fmt-conversion.h: fix pixfmt.h #include; fixes latest Libav Change fmt-conversion.h to include instead of which no longer indirectly includes the former. This fixes compilation with latest Libav. Also remove superfluous config.h #include. The pixfmt.h #include is needed for 'enum PixelFormat'. avutil.h already stopped including pixfmt.h more than a year ago, but that did not cause visible breakage at the time. AFAIK the C standard does not allow incomplete enum types, but it seems that GCC and other relevant compilers accept function declarations using not-yet-defined enum types without warnings. However, Libav now renamed 'enum PixelFormat' to 'enum AVPixelFormat', adding a '#define PixelFormat AVPixelFormat' for backwards compatibility. We need this compatibility define because we're still using the PixelFormat name, but it of course does not work if pixfmt.h is not included; thus the missing include now caused a compilation failure. --- fmt-conversion.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'fmt-conversion.h') diff --git a/fmt-conversion.h b/fmt-conversion.h index 9e133a8222..f7114b0aef 100644 --- a/fmt-conversion.h +++ b/fmt-conversion.h @@ -19,8 +19,7 @@ #ifndef MPLAYER_FMT_CONVERSION_H #define MPLAYER_FMT_CONVERSION_H -#include "config.h" -#include "libavutil/avutil.h" +#include enum PixelFormat imgfmt2pixfmt(int fmt); int pixfmt2imgfmt(enum PixelFormat pix_fmt); -- cgit v1.2.3