25 #include "common/scummsys.h" 26 #include "common/serializer.h" 27 #include "common/str.h" 28 #include "audio/mididrv.h" 29 #include "scumm/file.h" 30 #include "scumm/soundcd.h" 31 #include "scumm/soundse.h" 33 #define DIGI_SND_MODE_EMPTY 0 34 #define DIGI_SND_MODE_SFX 1 35 #define DIGI_SND_MODE_TALKIE 2 38 class SeekableSubReadStream;
44 class SeekableAudioStream;
51 struct MP3OffsetTable;
74 int16 _midiQueuePos, _midiQueue[0x100];
90 MP3OffsetTable *_offsetTable;
92 int64 _cachedSfxLocationInPak = -1;
93 int32 _cachedSfxLengthInPak = 0;
95 uint32 _queuedSfxOffset, _queuedTalkieOffset, _queuedSfxLen, _queuedTalkieLen;
96 byte _queuedSoundMode, _queuedSfxChannel;
99 uint16 _mouthSyncTimes[64];
106 bool _useRemasteredAudio =
false;
107 bool _enableAmbienceSounds =
false;
115 uint32 _speechTimerMod;
122 virtual void startSound(
int sound,
int heOffset = 0,
int heChannel = 0,
int heFlags = 0,
int heFreq = 0,
int hePan = 0,
int heVol = 0);
123 virtual void addSoundToQueue(
int sound,
int heOffset = 0,
int heChannel = 0,
int heFlags = 0,
int heFreq = 0,
int hePan = 0,
int heVol = 0);
125 virtual void modifySound(
int sound,
int offset,
int frequencyShift,
int pan,
int volume,
int flags) {};
127 void triggerSound(
int soundID);
128 void startTalkSound(uint32 offset, uint32 b,
int mode,
Audio::SoundHandle *handle = NULL);
129 void stopTalkSound();
130 bool isMouthSyncOff(uint pos);
131 virtual int isSoundRunning(
int sound)
const;
132 virtual bool isSoundInUse(
int sound)
const;
133 virtual void stopSound(
int sound);
134 virtual void stopAllSounds();
135 void soundKludge(
int *list,
int num);
136 void talkSound(uint32 offset, uint32 length,
int mode,
int channel = 0);
137 virtual void setupSound();
138 virtual void pauseSounds(
bool pause);
139 bool isSfxFileCompressed();
140 bool hasSfxFile()
const;
141 ScummFile *restoreDiMUSESpeechFile(
const char *fileName);
142 void extractSyncsFromDiMUSEMarker(
const char *marker);
143 void incrementSpeechTimer();
144 void resetSpeechTimer();
145 void startSpeechTimer();
146 void stopSpeechTimer();
147 bool speechIsPlaying();
150 void restoreAfterLoad();
152 bool isAudioDisabled();
154 void updateMusicTimer();
156 bool shouldInjectMISEAudio()
const;
157 void startRemasteredSpeech(
const char *msgString, uint16 roomNumber, uint16 actorTalking, uint16 numWaits);
160 bool isRolandLoom()
const {
161 return _soundCD->isRolandLoom();
166 return _soundCD->pollCD();
169 _soundCD->updateCD();
173 _soundCD->stopCDTimer();
175 void playCDTrack(
int track,
int numLoops,
int startFrame,
int duration) {
176 _soundCD->playCDTrack(track, numLoops, startFrame, duration);
178 int getCurrentCDSound()
const {
179 return _soundCD->getCurrentCDSound();
182 _soundCD->restoreCDAudioAfterLoad(info);
184 void setupMISEAudioParams(int32 scriptNum, int32 scriptOffset) {
185 _soundSE->setupMISEAudioParams(scriptNum, scriptOffset);
190 bool isSfxFinished()
const;
191 void processSfxQueues();
193 bool isSoundInQueue(
int sound)
const;
195 virtual void processSoundQueues();
MidiDriverFlags
Definition: mididrv.h:83
Definition: serializer.h:79
Definition: algorithm.h:29
Definition: serializer.h:308