The audio listener defines the global properties of the audio environment, it
defines where and how sounds and musics are heard.
If $(VIEW_LINK) is the eyes of the user, then
$(U Listener) is his ears (by the way, they are often linked together – same
position, orientation, etc.).
$(U Listener) is a simple interface, which allows to setup the listener in
the 3D audio environment (position and direction), and to adjust the global
volume.
Because the listener is unique in the scene, $(U Listener) only contains
static functions and doesn't have to be instanciated.
1 // Move the listener to the position (1, 0, -5)2 Listener.position = Vector3f(1, 0, -5);
3 4 // Make it face the right axis (1, 0, 0)5 Listener.direction = Vector3f(1, 0, 0);
6 7 // Reduce the global volume8 Listener.globalVolume = 50;
The audio listener defines the global properties of the audio environment, it defines where and how sounds and musics are heard.
If $(VIEW_LINK) is the eyes of the user, then $(U Listener) is his ears (by the way, they are often linked together – same position, orientation, etc.).
$(U Listener) is a simple interface, which allows to setup the listener in the 3D audio environment (position and direction), and to adjust the global volume.
Because the listener is unique in the scene, $(U Listener) only contains static functions and doesn't have to be instanciated.