Pyrogenesis  trunk
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | List of all members
CSoundManager Class Reference

#include <SoundManager.h>

Inheritance diagram for CSoundManager:
Inheritance graph
[legend]
Collaboration diagram for CSoundManager:
Collaboration graph
[legend]

Public Member Functions

 CSoundManager ()
 
virtual ~CSoundManager ()
 
void StartWorker ()
 
ISoundItemLoadItem (const VfsPath &itemPath)
 
ISoundItemItemForData (CSoundData *itemData)
 
ISoundItemItemForEntity (entity_id_t source, CSoundData *sndData)
 
Status ReloadChangedFiles (const VfsPath &path)
 
void ClearPlayListItems ()
 
void StartPlayList (bool doLoop)
 
void AddPlayListItem (const VfsPath &itemPath)
 
void SetMusicEnabled (bool isEnabled)
 
void SetSoundEnabled (bool enabled)
 
ALuint GetALSource (ISoundItem *anItem)
 
void ReleaseALSource (ALuint theSource)
 
ISoundItemItemFromData (CSoundData *itemData)
 
ISoundItemItemFromWAV (VfsPath &fname)
 
ISoundItemItemFromOgg (VfsPath &fname)
 
ISoundItemGetSoundItem (unsigned long itemRow)
 
unsigned long Count ()
 
void IdleTask ()
 
void SetMemoryUsage (long bufferSize, int bufferCount)
 
long GetBufferCount ()
 
long GetBufferSize ()
 
void PlayAsMusic (const VfsPath &itemPath, bool looping)
 
void PlayAsAmbient (const VfsPath &itemPath, bool looping)
 
void PlayAsUI (const VfsPath &itemPath, bool looping)
 
void PlayAsGroup (const VfsPath &groupPath, CVector3D sourcePos, entity_id_t source, bool ownedSound)
 
void PlayGroupItem (ISoundItem *anItem, ALfloat groupGain)
 
bool InDistress ()
 
void SetDistressThroughShortage ()
 
void SetDistressThroughError ()
 
void Pause (bool pauseIt)
 
void PauseMusic (bool pauseIt)
 
void PauseAmbient (bool pauseIt)
 
void PauseAction (bool pauseIt)
 
void SetAmbientItem (ISoundItem *anItem)
 
void SetMasterGain (float gain)
 
void SetMusicGain (float gain)
 
void SetAmbientGain (float gain)
 
void SetActionGain (float gain)
 
void SetUIGain (float gain)
 
- Public Member Functions inherited from ISoundManager
virtual ~ISoundManager ()
 

Static Public Member Functions

static void CreateSoundManager ()
 
static void SetEnabled (bool doEnable)
 
static Status ReloadChangedFileCB (void *param, const VfsPath &path)
 
static void CloseGame ()
 
static void al_ReportError (ALenum err, const char *caller, int line)
 
static void al_check (const char *caller, int line)
 
- Static Public Member Functions inherited from ISoundManager
static void CreateSoundManager ()
 
static void SetEnabled (bool doEnable)
 
static void CloseGame ()
 

Protected Member Functions

void InitListener ()
 
Status AlcInit ()
 
void SetMusicItem (ISoundItem *anItem)
 

Protected Attributes

ALCcontext * m_Context
 
ALCdevice * m_Device
 
ALSourceHolderm_ALSourceBuffer
 
ISoundItemm_CurrentTune
 
ISoundItemm_CurrentEnvirons
 
CSoundManagerWorkerm_Worker
 
CMutex m_DistressMutex
 
PlayListm_PlayListItems
 
SoundGroupMap m_SoundGroups
 
float m_Gain
 
float m_MusicGain
 
float m_AmbientGain
 
float m_ActionGain
 
float m_UIGain
 
bool m_Enabled
 
long m_BufferSize
 
int m_BufferCount
 
bool m_SoundEnabled
 
bool m_MusicEnabled
 
bool m_MusicPaused
 
bool m_AmbientPaused
 
bool m_ActionPaused
 
bool m_RunningPlaylist
 
bool m_PlayingPlaylist
 
bool m_LoopingPlaylist
 
long m_PlaylistGap
 
long m_DistressErrCount
 
long m_DistressTime
 

Private Member Functions

 NONCOPYABLE (CSoundManager)
 
 CSoundManager (CSoundManager *other)
 

Constructor & Destructor Documentation

CSoundManager::CSoundManager ( )
CSoundManager::~CSoundManager ( )
virtual
CSoundManager::CSoundManager ( CSoundManager other)
inlineprivate

Member Function Documentation

void CSoundManager::AddPlayListItem ( const VfsPath itemPath)
void CSoundManager::al_check ( const char *  caller,
int  line 
)
static
void CSoundManager::al_ReportError ( ALenum  err,
const char *  caller,
int  line 
)
static
Status CSoundManager::AlcInit ( )
protected
void CSoundManager::ClearPlayListItems ( )
static void CSoundManager::CloseGame ( )
static
unsigned long CSoundManager::Count ( )
static void CSoundManager::CreateSoundManager ( )
static
ALuint CSoundManager::GetALSource ( ISoundItem anItem)
long CSoundManager::GetBufferCount ( )
long CSoundManager::GetBufferSize ( )
ISoundItem* CSoundManager::GetSoundItem ( unsigned long  itemRow)
void CSoundManager::IdleTask ( )
virtual

Implements ISoundManager.

bool CSoundManager::InDistress ( )
virtual

Implements ISoundManager.

void CSoundManager::InitListener ( )
protected
ISoundItem * CSoundManager::ItemForData ( CSoundData itemData)
ISoundItem * CSoundManager::ItemForEntity ( entity_id_t  source,
CSoundData sndData 
)
ISoundItem* CSoundManager::ItemFromData ( CSoundData itemData)
ISoundItem* CSoundManager::ItemFromOgg ( VfsPath fname)
ISoundItem* CSoundManager::ItemFromWAV ( VfsPath fname)
ISoundItem * CSoundManager::LoadItem ( const VfsPath itemPath)
CSoundManager::NONCOPYABLE ( CSoundManager  )
private
void CSoundManager::Pause ( bool  pauseIt)
virtual

Implements ISoundManager.

void CSoundManager::PauseAction ( bool  pauseIt)
void CSoundManager::PauseAmbient ( bool  pauseIt)
void CSoundManager::PauseMusic ( bool  pauseIt)
void CSoundManager::PlayAsAmbient ( const VfsPath itemPath,
bool  looping 
)
virtual

Implements ISoundManager.

void CSoundManager::PlayAsGroup ( const VfsPath groupPath,
CVector3D  sourcePos,
entity_id_t  source,
bool  ownedSound 
)
virtual

Implements ISoundManager.

void CSoundManager::PlayAsMusic ( const VfsPath itemPath,
bool  looping 
)
virtual

Implements ISoundManager.

void CSoundManager::PlayAsUI ( const VfsPath itemPath,
bool  looping 
)
virtual

Implements ISoundManager.

void CSoundManager::PlayGroupItem ( ISoundItem anItem,
ALfloat  groupGain 
)
void CSoundManager::ReleaseALSource ( ALuint  theSource)
Status CSoundManager::ReloadChangedFileCB ( void *  param,
const VfsPath path 
)
static
Status CSoundManager::ReloadChangedFiles ( const VfsPath path)
void CSoundManager::SetActionGain ( float  gain)
virtual

Implements ISoundManager.

void CSoundManager::SetAmbientGain ( float  gain)
virtual

Implements ISoundManager.

void CSoundManager::SetAmbientItem ( ISoundItem anItem)
void CSoundManager::SetDistressThroughError ( )
void CSoundManager::SetDistressThroughShortage ( )
static void CSoundManager::SetEnabled ( bool  doEnable)
static
void CSoundManager::SetMasterGain ( float  gain)
virtual

Implements ISoundManager.

void CSoundManager::SetMemoryUsage ( long  bufferSize,
int  bufferCount 
)
void CSoundManager::SetMusicEnabled ( bool  isEnabled)
void CSoundManager::SetMusicGain ( float  gain)
virtual

Implements ISoundManager.

void CSoundManager::SetMusicItem ( ISoundItem anItem)
protected
void CSoundManager::SetSoundEnabled ( bool  enabled)
void CSoundManager::SetUIGain ( float  gain)
virtual

Implements ISoundManager.

void CSoundManager::StartPlayList ( bool  doLoop)
void CSoundManager::StartWorker ( )
virtual

Implements ISoundManager.

Member Data Documentation

float CSoundManager::m_ActionGain
protected
bool CSoundManager::m_ActionPaused
protected
ALSourceHolder* CSoundManager::m_ALSourceBuffer
protected
float CSoundManager::m_AmbientGain
protected
bool CSoundManager::m_AmbientPaused
protected
int CSoundManager::m_BufferCount
protected
long CSoundManager::m_BufferSize
protected
ALCcontext* CSoundManager::m_Context
protected
ISoundItem* CSoundManager::m_CurrentEnvirons
protected
ISoundItem* CSoundManager::m_CurrentTune
protected
ALCdevice* CSoundManager::m_Device
protected
long CSoundManager::m_DistressErrCount
protected
CMutex CSoundManager::m_DistressMutex
protected
long CSoundManager::m_DistressTime
protected
bool CSoundManager::m_Enabled
protected
float CSoundManager::m_Gain
protected
bool CSoundManager::m_LoopingPlaylist
protected
bool CSoundManager::m_MusicEnabled
protected
float CSoundManager::m_MusicGain
protected
bool CSoundManager::m_MusicPaused
protected
bool CSoundManager::m_PlayingPlaylist
protected
long CSoundManager::m_PlaylistGap
protected
PlayList* CSoundManager::m_PlayListItems
protected
bool CSoundManager::m_RunningPlaylist
protected
bool CSoundManager::m_SoundEnabled
protected
SoundGroupMap CSoundManager::m_SoundGroups
protected
float CSoundManager::m_UIGain
protected
CSoundManagerWorker* CSoundManager::m_Worker
protected

The documentation for this class was generated from the following files: