[FFmpeg-user] aevalsrc stereo auto-converted to mono?

Thierry Foucu tfoucu at gmail.com
Wed Feb 8 05:29:23 CET 2012

On Tue, Feb 7, 2012 at 3:06 PM, Nicolas George <
nicolas.george at normalesup.org> wrote:

> Le nonidi 19 pluviôse, an CCXX, Thierry Foucu a écrit :
> > I was trying to use aevalsrc to create a stereo input, but it seems that
> > the code auto insert a aconvert filter to downmix my stereo input to
> mono.
> >
> > Here is the output. Notice the aconvert filter being inserted and
> > converting my stereo to mono...
> > any option I should add to make sure the downmix does not happen?
> http://www.ffmpeg.org/faq.html#Using-_002df-lavfi_002c-audio-becomes-mono-for-no-apparent-reason_002e
> "3.15 Using '-f lavfi', audio becomes mono for no apparent reason."
> Please let us know if this is not enough to solve your problem.
> Regards,
Thanks Nicolas, now, this command works
./ffmpeg -f lavfi -i
-y /tmp/test.ts

I have a correct stereo stream.

i think the problem is that without the aconvert, the code is auto
inserting a aconvert filter, see output log
[abuffersink @ 0x2e42040] auto-inserting filter 'auto-inserted aconvert 0'
between the filter 'Parsed_aevalsrc_0' and the filter 'out'

the auto insertion is used because aevalsrc is outputting dbl and lavfi
seems to want to output s16.
[aconvert @ 0x2e48e60] fmt:dbl cl:stereo planar:1 -> fmt:s16 cl:mono

But i think there could be a bug here.
The auto inserting filter should not change the number of channels. It
should keep the same number of channels as the aevalsrc
and just convert the fmt from dbl to s16

More information about the ffmpeg-user mailing list