xyginext  0.2.0
Second generation of xygine game creation framework
Public Member Functions | Friends | List of all members
xy::AudioListener Class Referencefinal

Audio Listener component. The AudioListener component defines the point at which the active AudioSystem hears any playing AudioSources. Only one listener is active at a time, by default on the Scene's active camera entity. When using mono AudioEmitters spatialisation is calculated based on an AudioSource's position relative to the active AudioListener. More...

#include <AudioListener.hpp>

Public Member Functions

void setVolume (float volume)
 Sets the overall volume of the Listener. This will affect the perceived volume of all sounds being heard by the active listener. A volume of 0 will mute all audio, 1 plays back at 'normal' volume and anything greater will amplify any sounds heard by the listener.
 
float getVolume () const
 Returns the current volume of the listener.
 
void setDepth (float depth)
 Sets the depth of the listener relative to the scene. Positive numbers move the listener 'out' of the screen. By default the listener is at 0, on the same plane as the rest of the scene - this generally leads to a more pronounced stereo effect.
 

Friends

class AudioSystem
 

Detailed Description

Audio Listener component. The AudioListener component defines the point at which the active AudioSystem hears any playing AudioSources. Only one listener is active at a time, by default on the Scene's active camera entity. When using mono AudioEmitters spatialisation is calculated based on an AudioSource's position relative to the active AudioListener.