From 4bc287cedb1525b6720a34eb8f340d704a8f46ba Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Mon, 8 Mar 2010 10:20:14 +0000 Subject: [PATCH] Added extra ffmpeg version check --- src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp | 2 +- src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp b/src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp index 646ea2820..0c5346030 100644 --- a/src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp +++ b/src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp @@ -16,7 +16,7 @@ static int decode_audio(AVCodecContext *avctx, int16_t *samples, int *frame_size_ptr, const uint8_t *buf, int buf_size) { -#if LIBAVCODEC_VERSION_MAJOR >= 52 +#if LIBAVCODEC_VERSION_MAJOR >= 53 || (LIBAVCODEC_VERSION_MAJOR==52 && LIBAVCODEC_VERSION_MINOR>=32) // following code segment copied from ffmpeg's avcodec_decode_audio2() // implementation to avoid warnings about deprecated function usage. diff --git a/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp b/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp index ede9285d0..468065ecb 100644 --- a/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp +++ b/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp @@ -12,7 +12,7 @@ static int decode_video(AVCodecContext *avctx, AVFrame *picture, int *got_picture_ptr, const uint8_t *buf, int buf_size) { -#if LIBAVCODEC_VERSION_MAJOR >= 52 +#if LIBAVCODEC_VERSION_MAJOR >= 53 || (LIBAVCODEC_VERSION_MAJOR==52 && LIBAVCODEC_VERSION_MINOR>=32) // following code segment copied from ffmpeg avcodec_decode_video() implementation // to avoid warnings about deprecated function usage. AVPacket avpkt;