25 #include "common/util.h" 26 #include "common/mutex.h" 27 #include "audio/mixer.h" 28 #include "audio/mididrv.h" 45 virtual void loadMusic(
const char *name) = 0;
46 virtual void playMusic() = 0;
47 virtual void stopMusic() = 0;
48 virtual void fadeOutMusic() = 0;
50 virtual void playSound(
int mode,
int channel,
int param3,
int param4,
int param5,
int size) = 0;
51 virtual void playSound(
int channel,
int frequency,
const uint8 *data,
int size,
int volumeStep,
int stepCount,
int volume,
int repeat) = 0;
52 virtual void stopSound(
int channel) = 0;
53 virtual void setBgMusic(
int num) = 0;
63 class PCSoundFxPlayer;
71 void loadMusic(
const char *name)
override;
72 void playMusic()
override;
73 void stopMusic()
override;
74 void fadeOutMusic()
override;
76 void playSound(
int mode,
int channel,
int param3,
int param4,
int param5,
int size)
override;
77 void playSound(
int channel,
int frequency,
const uint8 *data,
int size,
int volumeStep,
int stepCount,
int volume,
int repeat)
override;
78 void stopSound(
int channel)
override;
79 void setBgMusic(
int num)
override;
83 PCSoundDriver *_soundDriver;
84 PCSoundFxPlayer *_player;
86 uint8 _currentMusic, _currentMusicStatus, _currentBgSlot;
95 void loadMusic(
const char *name)
override;
96 void playMusic()
override;
97 void stopMusic()
override;
98 void fadeOutMusic()
override;
100 void playSound(
int mode,
int channel,
int param3,
int param4,
int param5,
int size)
override;
101 void playSound(
int channel,
int frequency,
const uint8 *data,
int size,
int volumeStep,
int stepCount,
int volume,
int repeat)
override;
102 void stopSound(
int channel)
override;
103 void setBgMusic(
int num)
override;
106 PAULA_FREQ = 3579545,
119 void initialize(
int vol,
int volStep,
int stepCnt) {
121 volumeStep = volStep;
122 curStep = stepCount = stepCnt;
126 static const int _channelBalance[NUM_CHANNELS];
129 static void sfxTimerProc(
void *param);
130 void sfxTimerCallback();
135 static void musicTimerProc(
void *param);
136 void musicTimerCallback();
141 extern Sound *g_sound;
MusicType
Definition: mididrv.h:44
Definition: audiostream.h:50