MezzanineEngine March 18, 2012

Mezzanine::Audio::Listener Class Reference

This is the listener class used for 3D sound. More...

#include <audiolistener.h>

List of all members.

Public Member Functions

 Listener (cAudio::IListener *Listener)
 Class constructor. Internal use only.
 ~Listener ()
 Class destructor.
Vector3 GetDirection ()
 Gets the current direction of the listener.
Real GetMasterVolume ()
 Gets the master volume used to scale sound sources.
Real GetMetersPerUnit ()
 Gets the scale used by the manager for this listener.
Vector3 GetPosition ()
 Gets the current position of the listener.
Vector3 GetUpVector ()
 Sets the upward orientation of the listener.
Vector3 GetVelocity ()
 Gets the current velocity of the listener.
void Move (Vector3 Position)
 Moves the listener to a new location.
void SetDirection (Vector3 Direction)
 Sets the direction the listener is facing.
void SetMasterVolume (Real Volume)
 Sets the master volume for all sources heard by this listener.
void SetMetersPerUnit (Real Meters)
 Sets the scale to be used by the manager for this listener.
void SetPosition (Vector3 Position)
 Sets the listener position.
void SetUpVector (Vector3 Up)
 Sets the up direction for the listener.
void SetVelocity (Vector3 Velocity)
 Sets the velocity of the listener.

Protected Attributes

cAudio::IListener * AudioListener
 The internal implementation of the Audio Listener.

Detailed Description

This is the listener class used for 3D sound.

This is the listener class used for determining how 3D sound is played.

Definition at line 61 of file audiolistener.h.


Constructor & Destructor Documentation

Mezzanine::Audio::Listener::Listener ( cAudio::IListener *  Listener)

Class constructor. Internal use only.

Parameters:
ListenerPointer to the internal listener.

Definition at line 50 of file audiolistener.cpp.


Member Function Documentation

Vector3 Mezzanine::Audio::Listener::GetDirection ( )

Gets the current direction of the listener.

This function will get the current direction of the listener.

Returns:
Returns the current direction of the listener.

Definition at line 95 of file audiolistener.cpp.

Real Mezzanine::Audio::Listener::GetMasterVolume ( )

Gets the master volume used to scale sound sources.

This function will get the master volume, which is used to scale the volume of all sound sources heard by this listener.

Returns:
Returns the current scale used for adjusting the volume of all sources heard by this listener.

Definition at line 113 of file audiolistener.cpp.

Real Mezzanine::Audio::Listener::GetMetersPerUnit ( )

Gets the scale used by the manager for this listener.

This function will get the amount of meters per unit used in your game/simulation scale. The engine assumes you use meters, so default is 1.0.

Returns:
Returns the amount of meters per unit in your scale.

Definition at line 123 of file audiolistener.cpp.

Vector3 Mezzanine::Audio::Listener::GetPosition ( )

Gets the current position of the listener.

This function will get the current position of the listener.

Returns:
Returns the current position of the listener.

Definition at line 89 of file audiolistener.cpp.

Vector3 Mezzanine::Audio::Listener::GetUpVector ( )

Sets the upward orientation of the listener.

Sets which direction is up for the listener

Returns:
Returns the current up orientation of the listener.

Definition at line 101 of file audiolistener.cpp.

Vector3 Mezzanine::Audio::Listener::GetVelocity ( )

Gets the current velocity of the listener.

This function will get the current velocity of the listener.

Returns:
Returns the current velocity of the listener.

Definition at line 107 of file audiolistener.cpp.

void Mezzanine::Audio::Listener::Move ( Vector3  Position)

Moves the listener to a new location.

This function will set a new position and velocity of the listener.

Parameters:
PositionThe new position of the listener.

Definition at line 84 of file audiolistener.cpp.

void Mezzanine::Audio::Listener::SetDirection ( Vector3  Direction)

Sets the direction the listener is facing.

Sets the direction the listener is facing.

Parameters:
DirectionThe new direction for the listener.

Definition at line 64 of file audiolistener.cpp.

void Mezzanine::Audio::Listener::SetMasterVolume ( Real  Volume)

Sets the master volume for all sources heard by this listener.

This function will scale the volume for all sources heard by this listener by the amount provided.

Parameters:
VolumeThe amount by which to scale all sound sources heard.

Definition at line 79 of file audiolistener.cpp.

void Mezzanine::Audio::Listener::SetMetersPerUnit ( Real  Meters)

Sets the scale to be used by the manager for this listener.

This function will set the engines scale for use with sounds. Internally the engine assumes all units are in meters. If that is not the case then this function should be called to set the scale.

Parameters:
MetersThe amount of meters that are in one unit of your games scale.

Definition at line 118 of file audiolistener.cpp.

void Mezzanine::Audio::Listener::SetPosition ( Vector3  Position)

Sets the listener position.

Sets the listeners position.

Parameters:
PositionThe new position for the listener.

Definition at line 59 of file audiolistener.cpp.

void Mezzanine::Audio::Listener::SetUpVector ( Vector3  Up)

Sets the up direction for the listener.

Sets the direction that is up relative to the orientation of the listener. Default: +Y

Parameters:
UpThe new upward vector to be used by the listener.

Definition at line 69 of file audiolistener.cpp.

void Mezzanine::Audio::Listener::SetVelocity ( Vector3  Velocity)

Sets the velocity of the listener.

Sets the listeners velocity, for use in determining doppler effects.

Parameters:
VelocityThe new velocity for the listener.

Definition at line 74 of file audiolistener.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines