aboutsummaryrefslogtreecommitdiff
path: root/scumm/sound.h
diff options
context:
space:
mode:
authorMax Horn2003-07-14 21:37:45 +0000
committerMax Horn2003-07-14 21:37:45 +0000
commitbb87787314d90487d5c4762f94abd944cca196bb (patch)
tree1d470238cdc391ffc9259f057791efa7f72d7925 /scumm/sound.h
parent42d0b2e6f79378558832857b3f1ece4ea57164bf (diff)
downloadscummvm-rg350-bb87787314d90487d5c4762f94abd944cca196bb.tar.gz
scummvm-rg350-bb87787314d90487d5c4762f94abd944cca196bb.tar.bz2
scummvm-rg350-bb87787314d90487d5c4762f94abd944cca196bb.zip
fix for bug #769744 (COMI: Trying to append to a nonexistant stream)
svn-id: r9025
Diffstat (limited to 'scumm/sound.h')
-rw-r--r--scumm/sound.h15
1 files changed, 8 insertions, 7 deletions
diff --git a/scumm/sound.h b/scumm/sound.h
index fc9f6ab942..6214475dcd 100644
--- a/scumm/sound.h
+++ b/scumm/sound.h
@@ -22,6 +22,7 @@
#define SOUND_H
#include "scummsys.h"
+#include "sound/mixer.h"
class Bundle;
class DigitalTrackInfo;
@@ -100,7 +101,7 @@ protected:
public:
int32 _bundleMusicPosition;
- int _talkChannel; /* Mixer channel actor is talking on */
+ PlayingSoundHandle _talkChannelHandle; // Handle of mixer channel actor is talking on
bool _soundsPaused;
byte _sfxMode;
@@ -118,7 +119,7 @@ public:
void processSoundQues();
void playSound(int sound);
void processSfxQueues();
- int startTalkSound(uint32 offset, uint32 b, int mode);
+ void startTalkSound(uint32 offset, uint32 b, int mode, PlayingSoundHandle *handle = NULL);
void stopTalkSound();
bool isMouthSyncOff(uint pos);
int isSoundRunning(int sound) const;
@@ -135,7 +136,7 @@ public:
void pauseBundleMusic(bool state);
void bundleMusicHandler(Scumm *scumm);
void stopBundleMusic();
- int playBundleSound(char *sound);
+ void playBundleSound(char *sound, PlayingSoundHandle *handle);
uint32 decode12BitsSample(byte *src, byte **dst, uint32 size, bool stereo);
@@ -152,12 +153,12 @@ protected:
void clearSoundQue();
File *openSfxFile();
- int startSfxSound(File *file, int file_size);
+ void startSfxSound(File *file, int file_size, PlayingSoundHandle *handle);
void stopSfxSound();
bool isSfxFinished() const;
- int playSfxSound(void *sound, uint32 size, uint rate, bool isUnsigned);
- int playSfxSound_MP3(void *sound, uint32 size);
- int playSfxSound_Vorbis(void *sound, uint32 size);
+ void playSfxSound(void *sound, uint32 size, uint rate, bool isUnsigned, PlayingSoundHandle *handle);
+ void playSfxSound_MP3(void *sound, uint32 size, PlayingSoundHandle *handle);
+ void playSfxSound_Vorbis(void *sound, uint32 size, PlayingSoundHandle *handle);
int getCachedTrack(int track);
int playMP3CDTrack(int track, int numLoops, int startFrame, int endFrame);