[Libav-user] AAC encoder not returning final samples

Panicos Karkallis panicosk at gmail.com
Thu Aug 20 17:34:51 CEST 2015


Hi everyone,

I would like to thank you in advance for your help.

I am new to ffmpeg/avlib and what I am trying to do is just decode and
encode back again an aac file. I don't try to make any changes to the file
although the avlib encoder is producing a file with more initial padding
than expected and it is cropping the final frames of the audio clip.

I exported the avframes created by the decoder and all the file information
is there. It is at the encoding step that I am doing something wrong.

I am using the libfdk-aac decoder and encoder with the latest version of
ffmpeg in Visual Studio 2013.

I have attached a simplified version of my code and a link to a simple
audio file I have created to test my application.

I would really appreciate it if you can guide me on how to correct the
encoding step by retrieving the final samples and if possible remove the
delay created by the encoder.

Input file: https://www.dropbox.com/s/camqvmttq9a9vks/sinestereo.m4a?dl=0
Output of my program:
https://www.dropbox.com/s/liwfwr85v4g1ucx/audio.raw?dl=0

Looking forward to hearing from you.

Regards,

Panicos
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20150820/86b2c792/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: decode_encode_aac.cpp
Type: text/x-c++src
Size: 14431 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20150820/86b2c792/attachment.cpp>


More information about the Libav-user mailing list