[Openal] Directional source

Garin Hiebert garinh at cheesetoast.net
Sun May 28 14:21:33 PDT 2006


> I wonder if someone can help me to visualize how the inner and outer 
> angle of the sound cone works (in degrees)?

Visualize a source with its direction vector.  Now create two new 
vectors at +INNER_ANGLE/2 and -INNER_ANGLE/2.  If the listener is 
between those two vectors, then there is no attenuation due to the cone 
angle of the source.  Now create two new vectors at +OUTER_ANGLE/2 and 
-OUTER_ANGLE/2.  If the listener is between either set of INNER and 
OUTER vectors, then the cone-related gain is attenuated by linear 
interpolation between zero attenuation at INNER_ANGLE and 
AL_CONE_OUTER_GAIN at OUTER_ANGLE.  Between the two OUTER_ANGLE vectors 
opposite the source's direction, the cone-related gain is 
AL_CONE_OUTER_GAIN.

Garin



More information about the Openal mailing list