diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/sci/sound/decoders/sol.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/sci/sound/decoders/sol.cpp b/engines/sci/sound/decoders/sol.cpp index 280b24fd3a..a899cc4c77 100644 --- a/engines/sci/sound/decoders/sol.cpp +++ b/engines/sci/sound/decoders/sol.cpp @@ -70,13 +70,14 @@ static void deDPCM16(int16 *out, Common::ReadStream &audioStream, uint32 numByte * byte. */ static void deDPCM8Nibble(int16 *out, uint8 &sample, uint8 delta) { + const uint8 lastSample = sample; if (delta & 8) { sample -= tableDPCM8[delta & 7]; } else { sample += tableDPCM8[delta & 7]; } sample = CLIP<byte>(sample, 0, 255); - *out = (sample << 8) ^ 0x8000; + *out = ((lastSample + sample) << 7) ^ 0x8000; } /** |