Sound Class Reference
#include <sound.h>
List of all members.
Detailed Description
Sound engine.
Definition at line 37 of file sound.h.
Constructor & Destructor Documentation
Member Function Documentation
Installs the sound engine.
Definition at line 42 of file sound.cpp.
Removes all sound functionalities.
Definition at line 242 of file sound.cpp.
void Sound::playMusic |
( |
const std::string & |
path |
) |
|
Starts background music.
- Parameters:
-
| path | The full path to the music file. |
Definition at line 173 of file sound.cpp.
void Sound::stopMusic |
( |
|
) |
|
Stops currently running background music track.
Definition at line 186 of file sound.cpp.
void Sound::fadeInMusic |
( |
const std::string & |
path, |
|
|
int |
ms = 2000 | |
|
) |
| | |
Fades in background music.
- Parameters:
-
| path | The full path to the music file. |
| ms | Duration of fade-in effect (ms) |
Definition at line 200 of file sound.cpp.
void Sound::fadeOutMusic |
( |
int |
ms |
) |
|
Fades out currently running background music track.
- Parameters:
-
| ms | Duration of fade-out effect (ms) |
Definition at line 213 of file sound.cpp.
int Sound::getMaxVolume |
( |
|
) |
const |
void Sound::setMusicVolume |
( |
int |
volume |
) |
|
void Sound::setSfxVolume |
( |
int |
volume |
) |
|
void Sound::playSfx |
( |
const std::string & |
path |
) |
|
Plays an item.
- Parameters:
-
| path | The resource path to the sound file. |
Definition at line 229 of file sound.cpp.
void Sound::info |
( |
|
) |
[private] |
Logs various info about sound device.
Definition at line 79 of file sound.cpp.
void Sound::haltMusic |
( |
|
) |
[private] |
Halts and frees currently playing music.
Definition at line 254 of file sound.cpp.
Member Data Documentation
The documentation for this class was generated from the following files: