]> git.sesse.net Git - vlc/blobdiff - modules/codec/ffmpeg/video.c
Detect and allow older versions of ffmpeg to be used in conjunction with VLC.
[vlc] / modules / codec / ffmpeg / video.c
index 2ec7993b6846b08114abaf7e8b1821645770e119..bce47a94d0d5457e0c69bc9358f51833ec1e1e30 100644 (file)
 #include <vlc_input.h>                  /* hmmm, just for INPUT_RATE_DEFAULT */
 
 /* ffmpeg header */
-#ifdef HAVE_LIBAVCODEC_AVCODEC_H
+#if defined(HAVE_LIBAVCODEC_AVCODEC_H)
 #   include <libavcodec/avcodec.h>
+#elif defined(HAVE_FFMPEG_AVCODEC_H)
+#   include <ffmpeg/avcodec.h>
 #else
 #   include <avcodec.h>
 #endif
@@ -843,7 +845,7 @@ static void ffmpeg_CopyPicture( decoder_t *p_dec,
                 dest_pic.data[i] = p_pic->p[i].p_pixels;
                 dest_pic.linesize[i] = p_pic->p[i].i_pitch;
             }
-#if !defined(HAVE_LIBSWSCALE_SWSCALE_H) && !defined(HAVE_LIBSWSCALE_TREE)
+#if !defined(HAVE_LIBSWSCALE_SWSCALE_H) && !defined(HAVE_FFMPEG_SWSCALE_H) && !defined(HAVE_LIBSWSCALE_TREE)
             img_convert( &dest_pic, PIX_FMT_YUV420P,
                          (AVPicture *)p_ff_pic,
                          p_sys->p_context->pix_fmt,