summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarren Salt <linux@youmustbejoking.demon.co.uk>2008-09-13 12:48:10 +0100
committerDarren Salt <linux@youmustbejoking.demon.co.uk>2008-09-13 12:48:10 +0100
commit44e738a70be256a3ca0078212473f66cc9146f1e (patch)
tree34d8f27940a0eb062bcfede82b9a0ab0f8d75c8d
parent5fd01ca737a5083f73ae3a766b69877f309ae2b9 (diff)
downloadxine-lib-44e738a70be256a3ca0078212473f66cc9146f1e.tar.gz
xine-lib-44e738a70be256a3ca0078212473f66cc9146f1e.tar.bz2
Compilation fixes for ffmpeg API & ABI changes.
--HG-- extra : transplant_source : %A7%3F%40%BA%27%15%89%8B%F8%28%27%E6%EF%B8%22E%F1%AE%F8%D3
-rw-r--r--src/combined/ffmpeg/ff_audio_decoder.c2
-rw-r--r--src/combined/ffmpeg/ffmpeg_decoder.h4
2 files changed, 5 insertions, 1 deletions
diff --git a/src/combined/ffmpeg/ff_audio_decoder.c b/src/combined/ffmpeg/ff_audio_decoder.c
index b3b54ab0a..c2e3740e3 100644
--- a/src/combined/ffmpeg/ff_audio_decoder.c
+++ b/src/combined/ffmpeg/ff_audio_decoder.c
@@ -322,7 +322,7 @@ static void ff_audio_decode_data (audio_decoder_t *this_gen, buf_element_t *buf)
if (!this->output_open) {
if (!this->audio_bits || !this->audio_sample_rate || !this->audio_channels) {
- avcodec_decode_audio (this->context,
+ avcodec_decode_audio2 (this->context,
(int16_t *)this->decode_buffer,
&decode_buffer_size,
&this->buf[0],
diff --git a/src/combined/ffmpeg/ffmpeg_decoder.h b/src/combined/ffmpeg/ffmpeg_decoder.h
index f47421253..0f4ff1f1e 100644
--- a/src/combined/ffmpeg/ffmpeg_decoder.h
+++ b/src/combined/ffmpeg/ffmpeg_decoder.h
@@ -33,6 +33,10 @@
# include "../../libffmpeg/libavcodec/avcodec.h"
#endif
+#if LIBAVCODEC_VERSION_MAJOR > 51
+#define bits_per_sample bits_per_coded_sample
+#endif
+
typedef struct ff_codec_s {
uint32_t type;
enum CodecID id;