libwiigui 1.07
libwiigui is a GUI library for the Wii
 
Loading...
Searching...
No Matches
gui_sound.h
1#ifndef LIBWIIGUI_SOUND_H
2#define LIBWIIGUI_SOUND_H
3
4enum class SOUND {
5 PCM,
6 OGG
7};
8
10class GuiSound {
11public:
16 GuiSound(const u8 * s, s32 l, SOUND t);
18 ~GuiSound();
20 void Play();
22 void Stop();
24 void Pause();
26 void Resume();
29 bool IsPlaying();
32 void SetVolume(int v);
35 void SetLoop(bool l);
36protected:
37 const u8 * sound;
38 SOUND type;
39 s32 length;
40 s32 voice;
41 s32 volume;
42 bool loop;
43};
44
45#endif
Sound conversion and playback. A wrapper for other sound libraries - ASND, libmad,...
Definition: gui_sound.h:10
bool IsPlaying()
Definition: gui_sound.cpp:121
s32 length
Length of sound data.
Definition: gui_sound.h:39
s32 voice
Currently assigned ASND voice channel.
Definition: gui_sound.h:40
bool loop
Loop sound playback.
Definition: gui_sound.h:42
s32 volume
Sound volume (0-100)
Definition: gui_sound.h:41
void SetLoop(bool l)
Definition: gui_sound.cpp:152
void Resume()
Resume sound playback.
Definition: gui_sound.cpp:102
~GuiSound()
Destructor.
Definition: gui_sound.cpp:29
void Stop()
Stop sound playback.
Definition: gui_sound.cpp:64
void SetVolume(int v)
Definition: gui_sound.cpp:129
SOUND type
Sound format type (PCM or OGG)
Definition: gui_sound.h:38
const u8 * sound
Pointer to the sound data.
Definition: gui_sound.h:37
void Play()
Start sound playback.
Definition: gui_sound.cpp:37
void Pause()
Pause sound playback.
Definition: gui_sound.cpp:83