diff -up xine-lib-1.1.15/src/combined/ffmpeg/ff_audio_decoder.c.ffmpeg_api xine-lib-1.1.15/src/combined/ffmpeg/ff_audio_decoder.c --- xine-lib-1.1.15/src/combined/ffmpeg/ff_audio_decoder.c.ffmpeg_api 2008-07-16 01:13:03.000000000 +0200 +++ xine-lib-1.1.15/src/combined/ffmpeg/ff_audio_decoder.c 2008-12-17 22:54:15.000000000 +0100 @@ -269,7 +269,11 @@ static void ff_audio_decode_data (audio_ * bits/sample for some codecs (e.g. MS ADPCM) */ this->audio_bits = 16; +#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) this->context->bits_per_sample = this->audio_bits; +#else + this->context->bits_per_coded_sample = this->audio_bits; +#endif this->context->sample_rate = this->audio_sample_rate; this->context->channels = this->audio_channels; this->context->codec_id = this->codec->id; @@ -322,12 +326,21 @@ static void ff_audio_decode_data (audio_ if (!this->output_open) { if (!this->audio_bits || !this->audio_sample_rate || !this->audio_channels) { +#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) avcodec_decode_audio (this->context, (int16_t *)this->decode_buffer, &decode_buffer_size, &this->buf[0], this->size); this->audio_bits = this->context->bits_per_sample; +#else + avcodec_decode_audio2 (this->context, + (int16_t *)this->decode_buffer, + &decode_buffer_size, + &this->buf[0], + this->size); + this->audio_bits = this->context->bits_per_coded_sample; +#endif this->audio_sample_rate = this->context->sample_rate; this->audio_channels = this->context->channels; if (!this->audio_bits || !this->audio_sample_rate || !this->audio_channels) diff -up xine-lib-1.1.15/src/combined/ffmpeg/ff_video_decoder.c.ffmpeg_api xine-lib-1.1.15/src/combined/ffmpeg/ff_video_decoder.c --- xine-lib-1.1.15/src/combined/ffmpeg/ff_video_decoder.c.ffmpeg_api 2008-07-16 23:01:56.000000000 +0200 +++ xine-lib-1.1.15/src/combined/ffmpeg/ff_video_decoder.c 2008-12-17 22:54:56.000000000 +0100 @@ -939,7 +939,11 @@ static void ff_handle_header_buffer (ff_ this->context->extradata_size); } +#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) this->context->bits_per_sample = this->bih.biBitCount; +#else + this->context->bits_per_coded_sample = this->bih.biBitCount; +#endif } else {