cAudio::IListener Class Reference

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>

Inheritance diagram for cAudio::IListener:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual void setPosition (const cVector3 pos)=0
 Sets the position of the listener.
virtual void setDirection (const cVector3 dir)=0
 Sets the direction the listener is facing.
virtual void setUpVector (const cVector3 up)=0
 Sets the up vector to use for the listener.
virtual void setVelocity (const cVector3 vel)=0
 Sets the current velocity of the listener for doppler effects.
virtual void setMasterVolume (const float volume)=0
 Sets the global volume modifier (will effect all sources).
virtual void move (const cVector3 pos)=0
 Convenience function to automatically set the velocity and position for you in a single call.
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.
virtual void setMetersPerUnit (const float &meters)=0
 Sets the meters per user world unit for use with sound effects.
virtual float getMetersPerUnit (void) const =0
 Returns the meters per user world unit for use with sound effects.

Detailed Description

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 14 of file IListener.h.


Member Function Documentation

virtual void cAudio::IListener::move ( const cVector3  pos  )  [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

Parameters:
pos,: New position to move the listener to.

Implemented in cAudio::cListener.

virtual void cAudio::IListener::setDirection ( const cVector3  dir  )  [pure virtual]

Sets the direction the listener is facing.

Parameters:
dir,: New direction vector for the listener.

Implemented in cAudio::cListener.

virtual void cAudio::IListener::setMasterVolume ( const float  volume  )  [pure virtual]

Sets the global volume modifier (will effect all sources).

Parameters:
volume,: Volume to scale all sources by. Range: 0.0 to +inf.

Implemented in cAudio::cListener.

virtual void cAudio::IListener::setMetersPerUnit ( const float &  meters  )  [pure virtual]

Sets the meters per user world unit for use with sound effects.

Parameters:
meters,: Number of meters per world unit in your simulation.

Implemented in cAudio::cListener.

virtual void cAudio::IListener::setPosition ( const cVector3  pos  )  [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.

Parameters:
pos,: New position for the listener.

Implemented in cAudio::cListener.

virtual void cAudio::IListener::setUpVector ( const cVector3  up  )  [pure virtual]

Sets the up vector to use for the listener.

Default up vector is Y+, same as OpenGL.

Parameters:
up,: New up vector for the listener.

Implemented in cAudio::cListener.

virtual void cAudio::IListener::setVelocity ( const cVector3  vel  )  [pure virtual]

Sets the current velocity of the listener for doppler effects.

Parameters:
vel,: New velocity for the listener.

Implemented in cAudio::cListener.


The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Enumerations

Generated on Sat Feb 20 22:55:24 2010 for cAudio by  doxygen 1.6.2