42 std::vector<std::shared_ptr<ISound>> m_list;
47 bool m_random =
false;
57 std::recursive_mutex m_mutex;
76 SoundList(std::vector<std::shared_ptr<ISound>>& list,
bool random =
false);
#define AUD_NAMESPACE_END
Closes the audaspace namespace aud.
Definition Audaspace.h:119
#define AUD_NAMESPACE_BEGIN
Opens the audaspace namespace aud.
Definition Audaspace.h:116
#define AUD_API
Used for exporting symbols in the shared library.
Definition Audaspace.h:93
This class represents a type of sound source and saves the necessary values for it.
Definition ISound.h:40
This class allows to have a list of sound that will play sequentially or randomly with each playback.
Definition SoundList.h:37
void setRandomMode(bool random)
Sets the playback mode of the sound list.
SoundList(std::vector< std::shared_ptr< ISound > > &list, bool random=false)
Creates a new sound list and initializes it.
bool getRandomMode()
Returns the playback mode of the sound list.
void addSound(std::shared_ptr< ISound > sound)
Adds a sound to the list.
virtual std::shared_ptr< IReader > createReader()
Creates a reader for playback of the sound source.
int getSize()
Returns the amount of sounds in the list.
SoundList(bool random=false)
Creates a new, empty sound list.