aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scumm/smush/imuse_channel.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/scumm/smush/imuse_channel.cpp b/scumm/smush/imuse_channel.cpp
index 5106a7b76c..89cef462bb 100644
--- a/scumm/smush/imuse_channel.cpp
+++ b/scumm/smush/imuse_channel.cpp
@@ -307,9 +307,10 @@ void ImuseChannel::getSoundData(int16 * snd, int32 size) {
if(_dataSize <= 0 || _bitsize <= 8) error("invalid call to imuse_channel::read_sound_data()");
if(_channels == 2) size *= 2;
if(_rate == 11025) {
- for(int32 i = 0; i < size; i++)
+ for(int32 i = 0; i < size; i++) {
snd[i * 2] = READ_BE_UINT16(_sbuffer + 2 * i);
snd[i * 2 + 1] = snd[i * 2];
+ }
} else {
for(int32 i = 0; i < size; i++)
snd[i] = READ_BE_UINT16(_sbuffer + 2 * i);
@@ -325,9 +326,10 @@ void ImuseChannel::getSoundData(int8 * snd, int32 size) {
if(_dataSize <= 0 || _bitsize > 8) error("invalid call to imuse_channel::read_sound_data()");
if(_channels == 2) size *= 2;
if(_rate == 11025) {
- for(int32 i = 0; i < size; i++)
+ for(int32 i = 0; i < size; i++) {
snd[i * 2] = _sbuffer[i];
snd[i * 2 + 1] = _sbuffer[i];
+ }
} else {
for(int32 i = 0; i < size; i++)
snd[i] = _sbuffer[i];