aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTorbjörn Andersson2012-11-18 17:17:22 +0100
committerTorbjörn Andersson2012-11-18 17:56:13 +0100
commit34a8b5049e903f33a26b56da5fa32986a023feec (patch)
treecc09c6134f64edc4eb85ef1cd94c6800a46465e2
parent4f18a92f5a91eb502518846771bc8e82ff7da20a (diff)
downloadscummvm-rg350-34a8b5049e903f33a26b56da5fa32986a023feec.tar.gz
scummvm-rg350-34a8b5049e903f33a26b56da5fa32986a023feec.tar.bz2
scummvm-rg350-34a8b5049e903f33a26b56da5fa32986a023feec.zip
SCUMM: Use more correct (I think) way of converting samples
It shouldn't make any real difference, but it's probably more formally correct.
-rw-r--r--engines/scumm/player_mac.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/scumm/player_mac.cpp b/engines/scumm/player_mac.cpp
index 470bdaff30..2286a158ab 100644
--- a/engines/scumm/player_mac.cpp
+++ b/engines/scumm/player_mac.cpp
@@ -372,7 +372,7 @@ void Player_Mac::Instrument::generateSamples(int16 *data, int pitchModifier, int
}
}
- int newSample = ((_data[_pos] - 129) * 128 * volume) / 255;
+ int newSample = (((int16)((_data[_pos] << 8) ^ 0x8000)) * volume) / 255;
// Fade out the last 100 samples on each note. Even at low
// output sample rates this is just a fraction of a second,