aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/plugins/Input/ffmpeg/decoder_ffmpeg.cpp9
-rw-r--r--src/plugins/Input/ffmpeg/ffmpegmetadatamodel.cpp7
2 files changed, 13 insertions, 3 deletions
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
diff --git a/src/plugins/Input/ffmpeg/ffmpegmetadatamodel.cpp b/src/plugins/Input/ffmpeg/ffmpegmetadatamodel.cpp
index 933c766b6..cbabfe1f1 100644
--- a/src/plugins/Input/ffmpeg/ffmpegmetadatamodel.cpp
+++ b/src/plugins/Input/ffmpeg/ffmpegmetadatamodel.cpp
@@ -54,7 +54,12 @@ QHash<QString, QString> FFmpegMetaDataModel::audioProperties()
for (wma_idx = 0; wma_idx < m_in->nb_streams; wma_idx++)
{
c = m_in->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)
{