Mercurial > libavformat.hg
changeset 5362:6f5a1064e48a libavformat
Add a channels field to MPEG4AudioConfig.
author | alexc |
---|---|
date | Wed, 11 Nov 2009 20:24:23 +0000 |
parents | ce002ddccf1b |
children | 4696e193f943 |
files | flvdec.c mov.c |
diffstat | 2 files changed, 2 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/flvdec.c Mon Nov 09 01:10:55 2009 +0000 +++ b/flvdec.c Wed Nov 11 20:24:23 2009 +0000 @@ -410,9 +410,7 @@ MPEG4AudioConfig cfg; ff_mpeg4audio_get_config(&cfg, st->codec->extradata, st->codec->extradata_size); - if (cfg.chan_config > 7) - return -1; - st->codec->channels = ff_mpeg4audio_channels[cfg.chan_config]; + st->codec->channels = cfg.channels; st->codec->sample_rate = cfg.sample_rate; dprintf(s, "mp4a config channels %d sample rate %d\n", st->codec->channels, st->codec->sample_rate);
--- a/mov.c Mon Nov 09 01:10:55 2009 +0000 +++ b/mov.c Wed Nov 11 20:24:23 2009 +0000 @@ -434,9 +434,7 @@ MPEG4AudioConfig cfg; ff_mpeg4audio_get_config(&cfg, st->codec->extradata, st->codec->extradata_size); - if (cfg.chan_config > 7) - return -1; - st->codec->channels = ff_mpeg4audio_channels[cfg.chan_config]; + st->codec->channels = cfg.channels; if (cfg.object_type == 29 && cfg.sampling_index < 3) // old mp3on4 st->codec->sample_rate = ff_mpa_freq_tab[cfg.sampling_index]; else