Last change
on this file since 3020 was
3020,
checked in by simon, 19 years ago
|
/branches/sound/sound, branches/sound/hud: Made a few changes like a version which no longer compiles… Ah life is so hard on me. If it would compile, you would need to make a folder Data in hud and add a tga file named Font.tga with the letters in it.
|
-
Property svn:executable set to
*
|
File size:
898 bytes
|
Line | |
---|
1 | #ifndef SOUNDCONTROL_CLASS_H |
---|
2 | #define SOUNDCONTROL_CLASS_H |
---|
3 | |
---|
4 | #include "SDL/SDL.h" |
---|
5 | #include "SDL/SDL_mixer.h" |
---|
6 | #include <stdio.h> |
---|
7 | |
---|
8 | class SoundControl { |
---|
9 | public: |
---|
10 | static SoundControl* getInstance(); |
---|
11 | static void deleteInstance(); |
---|
12 | void setNumberOfChannels(int number_of_channels); |
---|
13 | void playMod(char* filename); |
---|
14 | void playWav(char* filename); |
---|
15 | void playOgg(char* filename); |
---|
16 | void volumeUp(); |
---|
17 | void volumeDown(); |
---|
18 | void trackRewind(); |
---|
19 | void forwardMusic(); |
---|
20 | void rewindMusic(); |
---|
21 | void pauseMusic(); |
---|
22 | void resumeMusic(); |
---|
23 | static void musicDone(); |
---|
24 | void handleKey(SDL_KeyboardEvent key); |
---|
25 | int main (void); |
---|
26 | static SoundControl* instance; |
---|
27 | int volume; |
---|
28 | int track_number; |
---|
29 | int audio_rate, audio_channels, audio_buffers; |
---|
30 | int done; |
---|
31 | Uint16 audio_format; |
---|
32 | int sfx_channel1; |
---|
33 | int sfx_channel2; |
---|
34 | int finished; |
---|
35 | private: |
---|
36 | void initialise(); |
---|
37 | SoundControl(); |
---|
38 | ~SoundControl(); |
---|
39 | }; |
---|
40 | |
---|
41 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.