cAudio
2.3.0
3d Audio Engine
|
Interface for the listener in cAudio. This class provides abilities to move and orient where your camera or user is in the audio world. More...
#include <IListener.h>
Public Member Functions | |
virtual void | setPosition (const cVector3 &pos)=0 |
Sets the position of the listener. More... | |
virtual void | setDirection (const cVector3 &dir)=0 |
Sets the direction the listener is facing. More... | |
virtual void | setUpVector (const cVector3 &up)=0 |
Sets the up vector to use for the listener. More... | |
virtual void | setVelocity (const cVector3 &vel)=0 |
Sets the current velocity of the listener for doppler effects. More... | |
virtual void | setMasterVolume (const float &volume)=0 |
Sets the global volume modifier (will effect all sources) More... | |
virtual void | move (const cVector3 &pos)=0 |
Convenience function to automatically set the velocity and position for you in a single call. More... | |
virtual cVector3 | getPosition (void) const =0 |
Returns the current position of the listener. | |
virtual cVector3 | getDirection (void) const =0 |
Returns the current direction of the listener. | |
virtual cVector3 | getUpVector (void) const =0 |
Returns the current up vector of the listener. | |
virtual cVector3 | getVelocity (void) const =0 |
Returns the current velocity of the listener. | |
virtual float | getMasterVolume (void) const =0 |
Returns the global volume modifier for all sources. | |
Interface for the listener in cAudio. This class provides abilities to move and orient where your camera or user is in the audio world.
Definition at line 13 of file IListener.h.
|
pure virtual |
Convenience function to automatically set the velocity and position for you in a single call.
Velocity will be set to new position - last position
pos | New position to move the listener to. |
Implemented in cAudio::cListener.
|
pure virtual |
Sets the direction the listener is facing.
dir | New direction vector for the listener. |
Implemented in cAudio::cListener.
|
pure virtual |
Sets the global volume modifier (will effect all sources)
volume | Volume to scale all sources by. Range: 0.0 to +inf. |
Implemented in cAudio::cListener.
|
pure virtual |
Sets the position of the listener.
Note that you will still have to set velocity after this call for proper doppler effects. Use move() if you'd like to have cAudio automatically handle velocity for you.
pos | New position for the listener. |
Implemented in cAudio::cListener.
|
pure virtual |
Sets the up vector to use for the listener.
Default up vector is Y+, same as OpenGL.
up | New up vector for the listener. |
Implemented in cAudio::cListener.
|
pure virtual |
Sets the current velocity of the listener for doppler effects.
vel | New velocity for the listener. |
Implemented in cAudio::cListener.