Diego Biurrun
3dde147ff9
cosmetics: Consistently place static, inline and av_cold attributes/keywords.
13 years ago
Diego Biurrun
f36d5c1422
Update Janne's email address.
13 years ago
Michael Niedermayer
744dd1d356
aacdec: Fix SCE parity check.
...
An unpaired SCE preceding a CPE only makes sense for front SCEs
preceding the first CPE.
Split from FFmpeg commit a8d67efa53
Signed-off-by: Alex Converse <alex.converse@gmail.com>
13 years ago
Michael Niedermayer
d53fe096e4
aacdec: Fix out of array writes (stack).
...
Set the element to channel vector (e2c_vec) size to be the maximum
number of aac channel elements. This makes it slightly larger than it
needs to be because CCEs are never mapped to output channel locations.
Also add a check that all input tags (legal or not) will fit.
Split from FFmpeg commit a8d67efa53
Signed-off-by: Alex Converse <alex.converse@gmail.com>
13 years ago
Michael Niedermayer
956fb91e03
aacdec: Support stereo streams that erroneously signal predefined channel configuration 1 (mono).
...
[alex.converse@mgail.com ]
Move code to get_che()
Update for AAC new channel configuration interface
Only set chan_config if output_configure succeeds.
Signed-off-by: Alex Converse <alex.converse@gmail.com>
13 years ago
Alex Converse
2564f6e6d4
aacdec: Reshuffle functions so get_che() can call set_default_channel_config() and output_configure().
13 years ago
Diego Biurrun
cfac648e6a
doxygen: Remove documentation for non-existing parameters; misc small fixes.
13 years ago
Alex Converse
5e239c7f9e
aacdec: Remove erroneous reference to global gain from the out of bounds scalefactor error message.
13 years ago
Alex Converse
1cd9a6154b
aac: fix infinite loop on end-of-frame with sequence of 1-bits.
...
Based-on-work-by: Ronald S. Bultje <rsbultje@gmail.com>
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
13 years ago
Alex Converse
b0f29db5c2
Mark mutable static data const where appropriate.
13 years ago
Martin Storsjö
9cf0841ef3
dsputil: Add ff_ prefix to the dsputil*_init* functions
...
Signed-off-by: Martin Storsjö <martin@martin.st>
13 years ago
Alex Converse
7b05025856
aacdec: Unify preconfigured layout and PCE layout.
13 years ago
Alex Converse
f1ecd0802d
aacdec: Support native channel layout when requested.
13 years ago
Alex Converse
37bed6ff3f
aacdec: Try to sniff a reasonable channel layout for PCE based configurations.
...
This changes the output order of multichannel PCE based streams.
13 years ago
Alex Converse
8ece266213
aacdec: Remove incorrect comment.
...
It was only correct when element ids met very specific criteria.
13 years ago
Alex Converse
e600a1e44a
aacdec: Simplify output configuration.
13 years ago
Alex Converse
b5fc571e4f
latmdec: Check AudioSpecificConfig length before decoding extradata.
...
This is different than a normal get_bits() over read because
decode_audio_specific_config() creates its own GetBitContext.
Fixes Bug 170.
13 years ago
Alex Converse
4acd43a295
aacdec: Turn off PS for multichannel files that use PCE based configs.
...
Fixes al_sbr_cm_48_5.1.mp4.
13 years ago
Martin Storsjö
132846b0c8
aacdec: Handle new extradata passed as side data
...
Signed-off-by: Martin Storsjö <martin@martin.st>
13 years ago
Alex Converse
021914e27f
aacdec: Cleanup decode_ics_info.
...
Remove unused function argument.
Return an AVERROR.
Don't zero out ICS on failure.
13 years ago
Alex Converse
5cd56e193f
aacdec: Use intfloat.h rather than local punning union.
13 years ago
Janne Grunau
d268b79e34
aac_latm: reconfigure decoder on audio specific config changes
13 years ago
Janne Grunau
fd095539d1
latmdec: fix audio specific config parsing
...
Pass the correct size in bits to mpeg4audio_get_config and add a flag
to disable parsing of the sync extension when the size is not known.
Latm with AudioMuxVersion 0 does not specify the size of the audio
specific config. Data after the audio specific config can be
misinterpreted as sync extension resulting in random and wrong configs.
13 years ago
Justin Ruggles
0eea212943
Add avcodec_decode_audio4().
...
Deprecate avcodec_decode_audio3().
Implement audio support in avcodec_default_get_buffer().
Implement the new audio decoder API in all audio decoders.
13 years ago
Alex Converse
963f685535
aacdec: Fix PS in ADTS.
...
Fixes File1.aac and Bug 80.
13 years ago
Michael Niedermayer
bc2dd36740
aacdec: allow output reconfiguration on channel changes
...
Locking the decoder against channel config changes in
parse_adts_frame_header() seems to be unnecessary and
streams with channel config changes are reported.
The sample in http://roundup.libav.org/issue999 still works.
Signed-off-by: Janne Grunau <janne-libav@jannau.net>
13 years ago
Justin Ruggles
71ccfb3f14
aac_latm: remove unneeded check for zero-size packet.
...
This is already checked by avcodec_decode_audio3()
13 years ago
Janne Grunau
28287045ca
cosmetics: simplify latm_decode_init
13 years ago
Janne Grunau
785f876cee
latm: avoid unnecessary reinit of the aac decoder
13 years ago
Janne Grunau
80e36425fb
aacdec: initialize sbr context only in new channel elements
13 years ago
Dustin Brody
9abc98737f
lavc: replace references to deprecated AVCodecContext.error_recognition to use AVCodecContext.err_recognition
...
Signed-off-by: Anton Khirnov <anton@khirnov.net>
13 years ago
Anton Khirnov
59a9a23581
lavc: use avpriv_ prefix for some mpeg4audio symbols used in lavf.
...
Specifically, ff_mpeg4audio_sample_rates, ff_mpeg4audio_get_config and
ff_copy_pce_data
13 years ago
Anton Khirnov
73ae27e17b
lavc: use avpriv_ prefix for ff_aac_parse_header().
...
It's used in lavf.
13 years ago
Mans Rullgard
d12294304a
aacdec: fix undefined shifts
...
Since nnz can be zero, this is needed to avoid a shift by 32.
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Alex Converse
44920d04ba
aac: Only set sample rate and object type from ADTS if output hasn't been configured.
...
Long term it would be nice to support error resilient reconfiguration
but right now setting this every frame does more harm than help.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
14 years ago
Alex Converse
06d37fede4
aac: Set SBR and PS to unsignalled during headerless and ADTS initialization.
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
14 years ago
Alex Converse
d8425ed4af
aac: Only output configure if audio was found.
...
Audio found is not triggered on a CCE because a CCE alone has no output.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
14 years ago
Alex Converse
94d47382e0
aac: Don't attempt to output configure an invalid channel configuration.
14 years ago
Dustin Brody
680b1852ab
aac: propagate error return values for AV_LOG_ERROR-triggering events
14 years ago
Alex Converse
a6c49f18ab
aac: Remove some suspicious illegal memcpy()s from LTP.
14 years ago
Anton Khirnov
ec6402b7c5
lavc: use designated initialisers for all codecs.
...
It's more readable and less prone to breakage.
14 years ago
Alex Converse
a58858d60d
lavf: Cleanup try_decode_frame() logic.
...
This fixes AAC playback in ffplay.
14 years ago
Benjamin Larsson
dafaef2fe1
Add support for aac streams in mp4/mov without extradata.
14 years ago
Justin Ruggles
e6c52cee54
Replace usages of av_get_bits_per_sample_fmt() with av_get_bytes_per_sample().
...
av_get_bits_per_sample_fmt() is deprecated.
14 years ago
Justin Ruggles
cef7d70181
aacdec: fix typo in scalefactor clipping check
14 years ago
Ronald S. Bultje
42da8ea8e8
LATM/AAC: Free previously initialized context on reinit.
...
Fixes memory leaks which are the result of overwriting already-initialized
MDCT contexts during context reinitialization, e.g. in valgrind
fate-aac-latm_000000001180bc60.
Signed-off-by: Diego Biurrun <diego@biurrun.de>
14 years ago
Justin Ruggles
9aa8193a23
Add floating-point sample format support to the ac3, eac3, dca, aac, and vorbis
...
decoders.
Based on patches by clsid2 in ffdshow-tryout.
14 years ago
Justin Ruggles
033a4a942a
aacdec: Use float instead of int16_t for ltp_state to avoid needless rounding.
14 years ago
Alex Converse
767848d761
aacdec: remove sf_scale and sf_offset.
...
Instead, scalefactors are adjusted by the offset amount, removing the need
for sf_scale, and the MDCT scales are adjusted to compensate for the higher
scalefactors. Floating-point output will be handled by modifying the MDCT
scales.
14 years ago
Justin Ruggles
6271794041
aacdec: use a scale of 2 in the LTP MDCT rather than doubling the coefficient
...
table values from the spec.
14 years ago