[vlc-devel] [PATCH 1/6] avcodec: replacement for av_sample_fmt_is_planar
Rafaël Carré
funman at videolan.org
Mon Feb 11 15:28:42 CET 2013
---
configure.ac | 3 +++
modules/codec/avcodec/avcodec.h | 9 +++++++++
2 files changed, 12 insertions(+)
diff --git a/configure.ac b/configure.ac
index 5b7ef1b..eff10ef 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2422,6 +2422,9 @@ AS_IF([test "${enable_avcodec}" != "no"], [
VLC_SAVE_FLAGS
CPPFLAGS="${CPPFLAGS} ${AVCODEC_CFLAGS}"
CFLAGS="${CFLAGS} ${AVCODEC_CFLAGS}"
+ LIBS="${LIBS} ${AVCODEC_LIBS}"
+ AC_CHECK_LIB(avutil, av_sample_fmt_is_planar,
+ AC_DEFINE([HAVE_AVUTIL_PLANAR], [1], [Define if libav* use planar audio formats]))
AC_CHECK_HEADERS(libavcodec/avcodec.h)
AC_CHECK_HEADERS(libavutil/avutil.h)
VLC_ADD_PLUGIN([avcodec])
diff --git a/modules/codec/avcodec/avcodec.h b/modules/codec/avcodec/avcodec.h
index 0005e90..a559947 100644
--- a/modules/codec/avcodec/avcodec.h
+++ b/modules/codec/avcodec/avcodec.h
@@ -21,6 +21,15 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
+
+#ifndef HAVE_AVUTIL_PLANAR
+# define av_sample_fmt_is_planar(x) (0)
+#endif
+
+
#include "chroma.h"
/* VLC <-> avcodec tables */
int GetFfmpegCodec( vlc_fourcc_t i_fourcc, int *pi_cat,
--
1.7.10.4
More information about the vlc-devel
mailing list