summaryrefslogtreecommitdiffstats
path: root/libmpcodecs/ad_ffmpeg.c
diff options
context:
space:
mode:
authorUoti Urpala <uau@mplayer2.org>2011-12-22 02:06:52 +0200
committerUoti Urpala <uau@mplayer2.org>2011-12-22 04:43:02 +0200
commit1bd5871762b9ddf50d7e2598a79c2e69c49b2757 (patch)
treec53da1b5d3bf251c1154011cdaa57e6bad2b6142 /libmpcodecs/ad_ffmpeg.c
parent37e4a928ca78bad9ea5e7ec07c0561c511de8ac9 (diff)
downloadmpv-1bd5871762b9ddf50d7e2598a79c2e69c49b2757.tar.bz2
mpv-1bd5871762b9ddf50d7e2598a79c2e69c49b2757.tar.xz
Libav API updates (remove most deprecated-in-0.7 uses)
Update various code using Libav libraries to remove use of API features that were deprecated at Libav release 0.7. I think this removes them all with the exception of URLContext functions still used in stream_ffmpeg.c (at least other uses that generated deprecation warnings with libraries from 0.7 are removed).
Diffstat (limited to 'libmpcodecs/ad_ffmpeg.c')
-rw-r--r--libmpcodecs/ad_ffmpeg.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/libmpcodecs/ad_ffmpeg.c b/libmpcodecs/ad_ffmpeg.c
index 762c80282d..e76c536957 100644
--- a/libmpcodecs/ad_ffmpeg.c
+++ b/libmpcodecs/ad_ffmpeg.c
@@ -281,8 +281,7 @@ static int decode_audio(sh_audio_t *sh_audio, unsigned char *buf, int minlen,
}
if (len2 > 0) {
if (avctx->channels >= 5) {
- int samplesize = av_get_bits_per_sample_format(
- avctx->sample_fmt) / 8;
+ int samplesize = av_get_bytes_per_sample(avctx->sample_fmt);
reorder_channel_nch(buf, AF_CHANNEL_LAYOUT_LAVC_DEFAULT,
AF_CHANNEL_LAYOUT_MPLAYER_DEFAULT,
avctx->channels,