[Vorbis-dev] Channels ordering bug
Nicolas George
nicolas.george at normalesup.org
Sat May 31 10:44:20 PDT 2008
Hi.
I think that vorbis-tools use a wrong order for channels when dealing with
5.1 surround WAV files.
More precisely, I find in the Vorbis specification that the output order is:
0: front left
1: front center
2: front right
3: rear left
4: rear right
5: LFE
(source: http://www.xiph.org/vorbis/doc/Vorbis_I_spec.html#id342556 )
At the same time, the order of channels in WAV files seems to be:
0: front left
1: front right
2: front center
3: LFE
4: rear left
5: rear right
(source: http://www.microsoft.com/whdc/device/audio/multichaud.mspx#E4C )
Now, in oggenc/audio.c, I see that the permutation array is used that way in
wav_ieee_read:
buffer[j][i] = buf[i*f->channels + f->channel_permute[j]];
To accommodate the specified orders, the permutation array should therefore
be:
0, 2, 1, 4, 5, 3
But wav_permute_matrix defines it as "0,2,1,5,3,4".
The same incorrect array is also present in oggdec.c.
I hope this problem can be fixed.
Regards,
--
Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.xiph.org/pipermail/vorbis-dev/attachments/20080531/8c1f1810/attachment.pgp
More information about the Vorbis-dev
mailing list