[Openal-devel] new panning algorithm
Christian Borss
christian.borss at rub.de
Mon Jan 19 01:39:24 PST 2009
Am 18. Jan. 2009 um 18:05 Uhr schrieb Chris Robinson:
>The center channel isn't used in spatial calculations because it's a bit
>ambiguous as to where it should be. The absolute center? Or between the front
>speakers?
The center speaker is typically placed between the front speakers as
recommended by "ITU-R BS.775":
http://en.wikipedia.org/wiki/Surround_sound#5.1_Channel_Surround_.283-2_Stereo.29_.28digital_discrete:_Dolby_Digital.2C_DTS.2C_SDDS.29
http://www.sengpielaudio.com/Surround-ITU-Wiedergabe.pdf
The second web site contains documents for German "Tonmeister" (sound
engineers).
>Often times in movies, the center speaker is left out for sound
>effects and used specifically as a voice track and/or some "special"
>sounds to draw the viewer's attention to.
I think, a rocket fired by an opponent in the front in a computer game
should definitely draw the gamers attention to the front. :-)
>For 7.1 surround-sound setups, it should use 6 speakers (2 front, 2 side, 2
>rear).
The center speaker was introduced to improve the localization in the
frontal region. So, why not make use of it?
I saw in the source code that you use this arrangement for 6.1 surround
setups. Thats why I used the front/side/rear-back speaker setup also in
my code. But normaly I would expect a
1 center
2 front
2 side
1 rear-back
speaker arrangement:
http://en.wikipedia.org/wiki/Surround_sound#6.1_Channel_Surround_.28digital_discrete:_DTS-ES.29
Would you agree to change the configuration to a DTS-ES arrangement?
>A quick test showed it seem to work well.
Great.
>I have question, though.. with this:
>
>pos = round(QUADRANT_NUM * aluFabs(im) / (aluFabs(re) + aluFabs(im)));
>
>what is supposed to happen if re and im are 0? Since they're the -Z and X
>coords, this is quite possible for head-relative sources that are left at
>0,0,0, and given the code, it would cause a 0/0 which wouldn't be very good.
In this case, DirGain is set to zero
DirGain = aluSqrt(Position[0] * Position[0] + Position[2] * Position[2]);
and AmbientGain is set to MaxAmbientGain:
AmbientGain = MaxAmbientGain * (1.0 - DirGain);
Thus, there is no directional sound and the sound is played back over
all speakers instead. In ioquake3 you can hear this effect, e.g., when
you fire your own weapons.
But you are right, it would be a more clean implementation to avoid a
division by zero.
Ciao,
Christian
P.S.: For those of you who will attend it: See you at the 35th
international AES convention "Audio for Games" in London!
--
Christian Borß, Dipl.-Ing. || Institut für Kommunikationsakustik
http://www.ika.ruhr-uni-bochum.de || Ruhr-Universität Bochum
Tel.: +49-(0)234-32-22470 || Universitätsstr. 150, IC1/33
Fax.: +49-(0)234-32-14165 || D-44780 Bochum (Germany)
More information about the Openal-devel
mailing list