The listener hears all the sounds in the world.
More...
#include <LSSSoundListener.h>
List of all members.
Detailed Description
The listener hears all the sounds in the world.
Class CSoundListener Description: The listener hears all the sounds in the world. There is only one listener in the game at a time. The gain property controls the master volume of all sound in the game.
Member Function Documentation
LSBOOL LSE_CALL lss::CSoundListener::DeviceActivated |
( |
| ) |
[protected] |
Notifies us that the given device has become active and we should send our buffer to it. A return of false from this function indicates the buffer could not be uploaded. This is considered a critical error by the engine.
- Returns:
- Returns true if the buffer could be reloaded.
LSVOID LSE_CALL lss::CSoundListener::DeviceWillClose |
( |
| ) |
[protected] |
Notifies us that the device is about to be lost (changed). We need to sever our connections to it, although we may retain our data/ settings.
const CVector3& LSE_CALL lss::CSoundListener::GetForward |
( |
| ) |
const |
Get our forward orientation value.
- Returns:
- Returns the forward orientation value of the listener.
LSSREAL LSE_CALL lss::CSoundListener::GetGain |
( |
| ) |
const |
Get our gain (volume).
- Returns:
- Returns the gain of the listener.
const CVector3& LSE_CALL lss::CSoundListener::GetPos |
( |
| ) |
const |
Get our position.
- Returns:
- Returns the position of the listener.
const CVector3& LSE_CALL lss::CSoundListener::GetUp |
( |
| ) |
const |
Get our up orientation value.
- Returns:
- Returns the up orientation value of the listener.
const CVector3& LSE_CALL lss::CSoundListener::GetVel |
( |
| ) |
const |
Get our velocity.
- Returns:
- Returns the velocity of the listener.
LSVOID LSE_CALL lss::CSoundListener::SetGain |
( |
LSSREAL |
_fGain | ) |
|
Set our gain (volume).
- Parameters:
-
_fGain | The new gain value. |
LSVOID LSE_CALL lss::CSoundListener::SetOrientation |
( |
const CVector3 & |
_vFor, |
|
|
const CVector3 & |
_vUp |
|
) |
| |
Set our orientation using forward/up vectors.
- Parameters:
-
_vFor | Forward vector. |
_vUp | Up vector. |
LSVOID LSE_CALL lss::CSoundListener::SetPos |
( |
const CVector3 & |
_vPos | ) |
|
Set our position.
- Parameters:
-
LSVOID LSE_CALL lss::CSoundListener::SetVel |
( |
const CVector3 & |
_vVel | ) |
|
Set our velocity.
- Parameters:
-
LSVOID LSE_CALL lss::CSoundListener::Tick |
( |
| ) |
|
Update the listener. Just updates the hardware/sound system if dirty and clears the dirty flag.
LSBOOL LSE_CALL lss::CSoundListener::Update |
( |
| ) |
[protected] |
Update our data. Send it to the hardware or sound system.
- Returns:
- Returns true if there are no errors related to the sound system after the update.
Member Data Documentation
Dirty flag indicating we need to update on the next tick.
Our gain (volume). 0 = nothing. 1 = full volume.
Our forward direction. -Z = forward.
Our up direction. Y = up.
The documentation for this class was generated from the following file: