[Libav-user] Transcoding audio to MP3 in mp4 container

Tobias Rapp t.rapp at noa-archive.com
Thu Feb 22 09:33:31 EET 2018


On 21.02.2018 16:22, Valeriy Shtoma wrote:
> Hi to all,
> 
> I'm using example(transcoding.c). After transcoding I get spoiled
> sound and sometimes error: "more samples than frame size
> (avcodec_encode_audio2)”. In this example, I have a filter graph,
> that convert audio sample fmts, channel layout and sample rate.
> 
> What am I doing wrong? How to change packet size, if there is
> required?

The asetnsamples filter allows to adjust the audio frame size, but I 
suppose there is a better/more idiomatic way to fix the problem.

Regards,
Tobias



More information about the Libav-user mailing list