22 #ifndef SCUMM_PLAYERS_PLAYER_MOD_H 23 #define SCUMM_PLAYERS_PLAYER_MOD_H 25 #include "scumm/scumm.h" 26 #include "audio/audiostream.h" 27 #include "audio/mixer.h" 28 #include "common/mutex.h" 43 virtual void setMusicVolume(
int vol);
45 virtual void startChannel(
int id,
void *data,
int size,
int rate, uint8 vol,
int loopStart = 0,
int loopEnd = 0, int8 pan = 0);
46 virtual void stopChannel(
int id);
47 virtual void setChannelVol(
int id, uint8 vol);
48 virtual void setChannelPan(
int id, int8 pan);
49 virtual void setChannelFreq(
int id,
int freq);
51 typedef void ModUpdateProc(
void *param);
53 virtual void setUpdateProc(ModUpdateProc *proc,
void *param,
int freq);
54 virtual void clearUpdateProc();
57 int readBuffer(int16 *buffer,
const int numSamples)
override {
59 do_mix(buffer, numSamples / 2);
62 bool isStereo()
const override {
return true; }
64 int getRate()
const override {
return _sampleRate; }
88 const int _sampleRate;
90 soundChan _channels[MOD_MAXCHANS];
94 virtual void do_mix(int16 *buf, uint len);
96 ModUpdateProc *_playproc;
int getRate() const override
Definition: player_mod.h:64
int readBuffer(int16 *buffer, const int numSamples) override
Definition: player_mod.h:57
bool endOfData() const override
Definition: player_mod.h:63
Definition: audiostream.h:50
Definition: player_mod.h:39
bool isStereo() const override
Definition: player_mod.h:62