[FFmpeg-user] AAC conversion from 7.1 channel to 2 channel
rohit a
rohit.tvm.86 at gmail.com
Sun May 5 06:08:18 CEST 2013
Hi,
For AAC conversion from 5.1 channels to 2 channels, the equation used in
surround_to_stereo() in libavodec/resample.c is
* l = av_clip_int16(fl + (0.5 * rl) + (0.7 * c));*
* r = av_clip_int16(fr + (0.5 * rr) + (0.7 * c));*
I was not able to find any algorithms/equations for converting 7.1 channel
to stereo.
Is there any equation for converting 7.1 channel to stereo ?
Regards,
Rohit
On Fri, May 3, 2013 at 5:47 PM, Carl Eugen Hoyos <cehoyos at ag.or.at> wrote:
> rohit a <rohit.tvm.86 <at> gmail.com> writes:
>
> > For AAC conversion from 5.1 channels to 2 channels,
> > ffmpeg code uses surround_to_stereo() in
> > libavcodec/Resample.c
>
> This looks outdated, I believe you should use
> libswresample.
>
> > In that the input data was packed in the format
> > fl, fr, c, lfe, rl, rr
> > fl = input[0]; // front left
> > fr = input[1]; // front right
> > c = input[2]; // center
> > lfe = input[3]; // low frequency effects
> > rl = input[4]; // rear left
> > rr = input[5]; // rear right
>
> > I would like to convert AAC 7.1 channels to 2 channels.
>
> Did you try?
> Without testing, I suspect it should work.
>
> > But i have no idea about how the input data is packed.
>
> FFmpeg internally expects wav channel order.
>
> > Can anyone please tell me how the input data format
> > is arranged for AAC 7.1 channels ?
>
> In aac, different channel orderings are possible,
> and usually it is not wav-order, but the aac
> decoder should correctly order the channels.
> (If it does not, this would be a bug, reports
> are very welcome!)
>
> Carl Eugen
>
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
More information about the ffmpeg-user
mailing list