aboutsummaryrefslogtreecommitdiff
path: root/scumm/sound.cpp
diff options
context:
space:
mode:
authorTravis Howell2004-07-13 05:02:27 +0000
committerTravis Howell2004-07-13 05:02:27 +0000
commita98f67562b659a7813916ec5a0329e1d466c813d (patch)
tree15657fa8311dc7e18259c01eaa80a43391aa6e30 /scumm/sound.cpp
parentae70a7034e7760338b7f10fd915f5e5f8946c270 (diff)
downloadscummvm-rg350-a98f67562b659a7813916ec5a0329e1d466c813d.tar.gz
scummvm-rg350-a98f67562b659a7813916ec5a0329e1d466c813d.tar.bz2
scummvm-rg350-a98f67562b659a7813916ec5a0329e1d466c813d.zip
Add correct sample rate for DOS HE 6.0 games.
svn-id: r14201
Diffstat (limited to 'scumm/sound.cpp')
-rw-r--r--scumm/sound.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/scumm/sound.cpp b/scumm/sound.cpp
index b2964f1782..f7ce771002 100644
--- a/scumm/sound.cpp
+++ b/scumm/sound.cpp
@@ -229,18 +229,18 @@ void Sound::playSound(int soundID) {
else if (READ_UINT32(ptr) == MKID('DIGI')) {
// TODO - discover what data the first chunk, HSHD, contains
// it might be useful here.
+ rate = READ_LE_UINT16(ptr + 22);
+
ptr += 8 + READ_BE_UINT32(ptr+12);
if (READ_UINT32(ptr) != MKID('SDAT'))
return; // abort
size = READ_BE_UINT32(ptr+4) - 8;
- // FIXME - what value here ?!? 11025 is just a guess based on strings in w32 bin, prev guess 8000
if (_overrideFreq) {
// Used by the piano in Fatty Bear's Birthday Surprise
rate = _overrideFreq;
_overrideFreq = 0;
- } else
- rate = 11025;
+ }
// Allocate a sound buffer, copy the data into it, and play
sound = (char *)malloc(size);
@@ -249,7 +249,6 @@ void Sound::playSound(int soundID) {
}
else if (READ_UINT32(ptr) == MKID('MRAW')) {
// pcm music in 3DO humongous games
- // TODO play via imuse so isSoundRunning can properly report music value?
ptr += 8 + READ_BE_UINT32(ptr+12);
if (READ_UINT32(ptr) != MKID('SDAT'))
return;