[Openal] 3D Sound and moving Listener

Jeremy Henry jeremy_h at hotmail.com
Thu Nov 2 11:05:45 PST 2006


We want to have certain static ojbects emit sounds in our game and fade in 
and out as the camera moves around the objects.  In our project we are 
updating the listener with...
alListenerfv(AL_POSITION,    ListenerPos);
alListenerfv(AL_VELOCITY,    ListenerVel);
alListenerfv(AL_ORIENTATION, ListenerOri);
but there is no change to the sounds volume.  I then downloaded this 
tutorial from devmaster.net
http://www.devmaster.net/articles/openal-tutorials/lesson2.php where it had 
a source moving away from a static listener.  I changed it so that the 
static listener was moving and the source itself was static and got the same 
problem as our project.


PS Thanks for the tip on handling the error in alGenSource to know when we 
hit the limit of channels being used.  Worked that to make a smooth way of 
kicking out lower priority sounds and retrying on the higher one.

_________________________________________________________________
Try Search Survival Kits: Fix up your home and better handle your cash with 
Live Search! 
http://imagine-windowslive.com/search/kits/default.aspx?kit=improve&locale=en-US&source=hmtagline



More information about the Openal mailing list