* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
+/* VLC <-> avcodec tables */
int GetFfmpegCodec( vlc_fourcc_t i_fourcc, int *pi_cat,
int *pi_ffmpeg_codec, const char **ppsz_name );
int GetVlcFourcc( int i_ffmpeg_codec, int *pi_cat,
vlc_fourcc_t *pi_fourcc, const char **ppsz_name );
+int TestFfmpegChroma( const int i_ffmpeg_id, const vlc_fourcc_t i_vlc_fourcc );
+int GetFfmpegChroma( int *i_ffmpeg_chroma, const video_format_t fmt );
+int GetVlcChroma( video_format_t *fmt, const int i_ffmpeg_chroma );
+
picture_t * DecodeVideo ( decoder_t *, block_t ** );
aout_buffer_t * DecodeAudio( decoder_t *, block_t ** );
/*****************************************************************************
- * chroma.h: libavutil <-> libvlc conversion routines
+ * chroma.c: libavutil <-> libvlc conversion routines
*****************************************************************************
* Copyright (C) 1999-2008 the VideoLAN team
* $Id$
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 021100301, USA.
*****************************************************************************/
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#include <vlc_common.h>
+#include <vlc_codec.h>
+
+#ifdef HAVE_LIBAVCODEC_AVCODEC_H
+# include <libavcodec/avcodec.h>
+#elif defined(HAVE_FFMPEG_AVCODEC_H)
+# include <ffmpeg/avcodec.h>
+#else
+# include <avcodec.h>
+#endif
+#include "avcodec.h"
+
/*****************************************************************************
* Chroma fourcc -> ffmpeg_id mapping
*****************************************************************************/
{ 0, 0, 0, 0, 0 }
};
-static inline int TestFfmpegChroma( const int i_ffmpeg_id, const vlc_fourcc_t i_vlc_fourcc )
+int TestFfmpegChroma( const int i_ffmpeg_id, const vlc_fourcc_t i_vlc_fourcc )
{
for( int i = 0; chroma_table[i].i_chroma != 0; i++ )
{
}
/* FIXME special case the RGB formats */
-static inline int GetFfmpegChroma( int *i_ffmpeg_chroma, const video_format_t fmt )
+int GetFfmpegChroma( int *i_ffmpeg_chroma, const video_format_t fmt )
{
for( int i = 0; chroma_table[i].i_chroma != 0; i++ )
{
return VLC_EGENERIC;
}
-static inline int GetVlcChroma( video_format_t *fmt, const int i_ffmpeg_chroma )
+int GetVlcChroma( video_format_t *fmt, const int i_ffmpeg_chroma )
{
/* TODO FIXME for rgb format we HAVE to set rgb mask/shift */
for( int i = 0; chroma_table[i].i_chroma != 0; i++ )