Mercurial > libavcodec.hg
changeset 10657:168ea860d58f libavcodec
aac: Set sample rate in avctx from ADTS header (if not already set by some
other means)
author | andoma |
---|---|
date | Tue, 08 Dec 2009 19:20:36 +0000 |
parents | 34911596ffed |
children | 8a7d79132993 |
files | aac.c |
diffstat | 1 files changed, 2 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/aac.c Tue Dec 08 17:38:02 2009 +0000 +++ b/aac.c Tue Dec 08 19:20:36 2009 +0000 @@ -1692,6 +1692,8 @@ ac->m4ac.sample_rate = hdr_info.sample_rate; ac->m4ac.sampling_index = hdr_info.sampling_index; ac->m4ac.object_type = hdr_info.object_type; + if (!ac->avccontext->sample_rate) + ac->avccontext->sample_rate = hdr_info.sample_rate; if (hdr_info.num_aac_frames == 1) { if (!hdr_info.crc_absent) skip_bits(gb, 16);