#include <audiomanager.h>
Public Types | |
enum | AUDIO_CHANNEL { AUDIO_CENTER_CHANNEL = -1, AUDIO_LEFT_CHANNEL = 0, AUDIO_LEFT_HALF_CHANNEL = 1, AUDIO_RIGHT_CHANNEL = 3, AUDIO_RIGHT_HALF_CHANNEL = 2 } |
This is for LR panning effects. | |
enum | AUDIO_CHANNEL { AUDIO_CENTER_CHANNEL = -1, AUDIO_LEFT_CHANNEL = 0, AUDIO_LEFT_HALF_CHANNEL = 1, AUDIO_RIGHT_CHANNEL = 3, AUDIO_RIGHT_HALF_CHANNEL = 2 } |
This is for LR panning effects. | |
Public Member Functions | |
OPENCITY_ERR_CODE | OpenAudio (void) |
OPENCITY_ERR_CODE | CloseAudio (void) |
OPENCITY_ERR_CODE | LoadMusicList (const string &csrFilename, const string &csrPrefix="") |
const uint & | GetNumberMusic (void) const |
bool | PlayingMusic (void) const |
OPENCITY_ERR_CODE | PlayMusic (const uint &rcuiMusicIndex, const int &rciLoops=1) |
OPENCITY_ERR_CODE | PlayNextMusic (const int &rciLoops=1) |
OPENCITY_ERR_CODE | PlayPreviousMusic (const int &rciLoops=1) |
void | StopMusic (void) const |
void | ToggleRandomMusic (void) |
void | ToggleMusic (void) |
void | VolumeMusic (const int &rciVol) const |
OPENCITY_ERR_CODE | LoadSoundList (const string &csrFilename, const string &csrPrefix="") |
const uint & | GetNumberSound (void) const |
OPENCITY_ERR_CODE | PlaySound (const uint &rcuiSoundIndex, const AUDIO_CHANNEL &enumChannel=AUDIO_CENTER_CHANNEL) |
void | ToggleSound (void) |
void | VolumeSound (const int &rciVol) const |
OPENCITY_ERR_CODE | OpenAudio (void) |
OPENCITY_ERR_CODE | CloseAudio (void) |
OPENCITY_ERR_CODE | LoadMusicList (const string &csrFilename, const string &csrPrefix="") |
const uint & | GetNumberMusic (void) const |
bool | PlayingMusic (void) const |
OPENCITY_ERR_CODE | PlayMusic (const uint &rcuiMusicIndex, const int &rciLoops=1) |
OPENCITY_ERR_CODE | PlayNextMusic (const int &rciLoops=1) |
OPENCITY_ERR_CODE | PlayPreviousMusic (const int &rciLoops=1) |
void | StopMusic (void) const |
void | ToggleRandomMusic (void) |
void | ToggleMusic (void) |
void | VolumeMusic (const int &rciVol) const |
OPENCITY_ERR_CODE | LoadSoundList (const string &csrFilename, const string &csrPrefix="") |
const uint & | GetNumberSound (void) const |
OPENCITY_ERR_CODE | PlaySound (const uint &rcuiSoundIndex, const AUDIO_CHANNEL &enumChannel=AUDIO_CENTER_CHANNEL) |
void | ToggleSound (void) |
void | VolumeSound (const int &rciVol) const |
Private Member Functions | |
OPENCITY_ERR_CODE | ParseM3UList (const string &csrFilename, vector< string > &vectorFilename, uint &uiNumberFiles) |
Private Attributes | |
bool | boolAudioDeviceInitialized |
bool | boolMusicEnabled |
bool | boolSoundEnabled |
uint | uiNumberSound |
uint | uiNumberMusic |
uint | uiCurrentMusic |
bool | boolRandomMusic |
string | strSoundList |
vector< string > | vectorSoundFilename |
vector< Mix_Chunk * > | vectorpSoundChunk |
string | strMusicList |
vector< string > | vectorMusicFilename |
bool | boolShuffleMusic |
Mix_Music * | pMusicData |
Definition at line 49 of file audiomanager.h.
|
Set the internal filename to the given M3U music list |
|
Set the internal filename to the given M3U music list Definition at line 61 of file audiomanager.cpp. |
|
Set the internal filename to the given M3U sound list. In constrast of LoadMusicList(), it loads all the sounds specified by the music list into memory for better performance. |
|
Set the internal filename to the given M3U sound list. In constrast of LoadMusicList(), it loads all the sounds specified by the music list into memory for better performance. Definition at line 163 of file audiomanager.cpp. |
|
WARNING: this method must be called before any use of AudioManager |
|
WARNING: this method must be called before any use of AudioManager Definition at line 44 of file audiomanager.cpp. |