[libav-devel] [PATCH 2/3] libfdk-aacdec: Always decode into an intermediate buffer
lu_zero at gentoo.org
Fri Aug 14 14:06:33 CEST 2015
On 14/08/15 13:21, Martin Storsjö wrote:
> On Fri, 14 Aug 2015, Luca Barbato wrote:
>> On 14/08/15 10:36, Martin Storsjö wrote:
>>> For ADTS streams, the output format (number of channels, frame size)
>>> can change at any point (with the latest version of fdk-aac, the decoder
>>> seems to change format after a handful of frames, not outputting the
>>> right format immediately, for cases that worked fine with the earlier
>>> version of the lib).
>>> Previously, the decoder decoded straight into the output frame once the
>>> number of channels and frame size was known. This obviously does not
>>> work if the number of channels or frame size changes.
>>> The alternative would be to allocate the AVFrame with the maximum number
>>> of channels and frame size, and change them afterward decoding into it,
>>> but that may cause confusion to users e.g. of the get_buffer callback.
>>> This solution should be more robust.
>>> CC: libav-stable at libav.org
>>> libavcodec/libfdk-aacdec.c | 68
>>> 1 file changed, 18 insertions(+), 50 deletions(-)
>> Sounds ok, fdk does provide a define with its max parameters in case?
> Not that I know of.
The number of channels is checked to be less than the maximum if the
library goes up to 12?
More information about the libav-devel