From a82a8cd70310fd5a104e1a3df6c6ae7459565330 Mon Sep 17 00:00:00 2001 From: trialuser02 Date: Tue, 10 May 2011 16:05:14 +0000 Subject: fixed recent ffmpeg support git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@2183 90c681e8-e032-0410-971d-27865f9a5e38 --- src/plugins/Input/ffmpeg/decoder_ffmpeg.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src/plugins/Input/ffmpeg/decoder_ffmpeg.cpp') diff --git a/src/plugins/Input/ffmpeg/decoder_ffmpeg.cpp b/src/plugins/Input/ffmpeg/decoder_ffmpeg.cpp index 902f6c9d8..d243e2ba3 100644 --- a/src/plugins/Input/ffmpeg/decoder_ffmpeg.cpp +++ b/src/plugins/Input/ffmpeg/decoder_ffmpeg.cpp @@ -155,14 +155,19 @@ bool DecoderFFmpeg::initialize() for (wma_idx = 0; wma_idx < (int)ic->nb_streams; wma_idx++) { c = ic->streams[wma_idx]->codec; - if (c->codec_type == CODEC_TYPE_AUDIO) break; +#if LIBAVCODEC_VERSION_MAJOR < 53 + if (c->codec_type == CODEC_TYPE_AUDIO) +#else + if (c->codec_type == AVMEDIA_TYPE_AUDIO) +#endif + break; } if (c->channels > 0) c->request_channels = qMin(2, c->channels); else c->request_channels = 2; - + #if (LIBAVCODEC_VERSION_INT >= ((52<<16)+(101<<8)+0)) av_dump_format(ic,0,0,0); #else -- cgit v1.2.3-13-gbd6f