OpenAL implementation of the sound system.
More...
#include "SoundSysImpl.hpp"
OpenAL implementation of the sound system.
Creates a 2 dimensional sound object using the properties of the passed sound shader.
- Parameters
-
SoundShader | Sound shader to use with this sound object. |
Implements SoundSysI.
Creates a 3 dimensional sound object using the properties of the passed sound shader.
- Parameters
-
SoundShader | Sound shader to use with this sound object. |
Implements SoundSysI.
void SoundSysImplT::DeleteSound |
( |
SoundI * |
Sound | ) |
|
|
virtual |
Deletes a previously created sound object.
- Parameters
-
Sound | The sound object to delete. |
Implements SoundSysI.
Creates an instance of the OpenAL sound system.
float SoundSysImplT::GetMasterVolume |
( |
| ) |
|
|
virtual |
Gets the master volume currently set for this sound system.
- Returns
- The current master volume [0, 1].
Implements SoundSysI.
int SoundSysImplT::GetPreferenceNr |
( |
| ) |
|
|
virtual |
Returns the preference number for this sound system, so calling code can decide which sound system to use.
- Returns
- Preference number.
Implements SoundSysI.
bool SoundSysImplT::Initialize |
( |
| ) |
|
|
virtual |
Initializes the sound system.
Implements SoundSysI.
bool SoundSysImplT::IsSupported |
( |
| ) |
|
|
virtual |
Determine if the sound system is supported on this platform.
- Returns
- Whether or not the sound system is supported.
Implements SoundSysI.
bool SoundSysImplT::PlaySound |
( |
const SoundI * |
Sound | ) |
|
|
virtual |
Plays a sound on a channel.
- Parameters
-
Sound | The sound object that should be played. |
- Returns
- true if sound is played on a channel, false if no channel was free (and playing sound have all greater priority than this sound).
Implements SoundSysI.
void SoundSysImplT::Release |
( |
| ) |
|
|
virtual |
Releases the sound system and removes all sound data from memory.
Implements SoundSysI.
void SoundSysImplT::SetMasterVolume |
( |
float |
Volume | ) |
|
|
virtual |
Sets the master volume for this sound system.
- Parameters
-
Volume | The new master volume. Value has to be 0, 1. |
Implements SoundSysI.
void SoundSysImplT::Update |
( |
| ) |
|
|
virtual |
Upates all channels that are currently being played according to the properties of their sound object.
Implements SoundSysI.
Updates the position, velocity and orientation of the listener.
- Parameters
-
Position | Position of the listener in the 3D Space. |
Velocity | Velocity of the listener. |
OrientationForward | Forward orientation of the listener (unit length vector). |
OrientationUp | Upwards orientation of the listener (unit length vector). |
Implements SoundSysI.
The documentation for this class was generated from the following files:
- Libs/SoundSystem/SoundSysOpenAL/SoundSysImpl.hpp
- Libs/SoundSystem/SoundSysOpenAL/SoundSysImpl.cpp