]> git.sesse.net Git - mlt/commitdiff
Fix incorrect precompiler conditionals for libav/ffmpeg versions.
authorBrian Matherly <pez4brian@yahoo.com>
Sun, 18 Mar 2012 19:18:47 +0000 (14:18 -0500)
committerBrian Matherly <pez4brian@yahoo.com>
Sun, 18 Mar 2012 19:18:47 +0000 (14:18 -0500)
Needed to support ffmpeg 0.9 and 0.10 releases.

src/modules/avformat/consumer_avformat.c
src/modules/avformat/producer_avformat.c

index 0b0322ead2550044e3d9117136740b0b01351829..424ad9f5b244b698ec6803fb86bd7c9dbfab2d97 100644 (file)
@@ -237,7 +237,7 @@ static int consumer_start( mlt_consumer consumer )
                mlt_properties_set_data( properties, "acodec", codecs, 0, (mlt_destructor) mlt_properties_close, NULL );
                mlt_properties_set_data( doc, "audio_codecs", codecs, 0, NULL, NULL );
                while ( ( codec = av_codec_next( codec ) ) )
-#if LIBAVCODEC_VERSION_INT >= ((53<<16)+(34<<8)+0)
+#if LIBAVCODEC_VERSION_INT >= ((54<<16)+(0<<8)+0)
                        if ( ( codec->encode || codec->encode2 ) && codec->type == CODEC_TYPE_AUDIO )
 #else
                        if ( codec->encode && codec->type == CODEC_TYPE_AUDIO )
@@ -261,7 +261,7 @@ static int consumer_start( mlt_consumer consumer )
                mlt_properties_set_data( properties, "vcodec", codecs, 0, (mlt_destructor) mlt_properties_close, NULL );
                mlt_properties_set_data( doc, "video_codecs", codecs, 0, NULL, NULL );
                while ( ( codec = av_codec_next( codec ) ) )
-#if LIBAVCODEC_VERSION_INT >= ((53<<16)+(34<<8)+0)
+#if LIBAVCODEC_VERSION_INT >= ((54<<16)+(0<<8)+0)
                        if ( (codec->encode || codec->encode2) && codec->type == CODEC_TYPE_VIDEO )
 #else
                        if ( codec->encode && codec->type == CODEC_TYPE_VIDEO )
index 39fbda091b5a5c4a47ab8bff6815a75987f29def..8465d210118217e3c7d668891d49f6400916af98 100644 (file)
@@ -1264,7 +1264,7 @@ static void convert_image( AVFrame *frame, uint8_t *buffer, int pix_fmt,
 
        // extract alpha from planar formats
        if ( ( pix_fmt == PIX_FMT_YUVA420P
-#if LIBAVUTIL_VERSION_INT >= ((51<<16)+(35<<8)+0)
+#if LIBAVUTIL_VERSION_INT >= ((51<<16)+(35<<8)+101)
                        || pix_fmt == PIX_FMT_YUVA444P
 #endif
                        ) &&