diff options
author | Torbjörn Andersson | 2006-04-06 18:55:39 +0000 |
---|---|---|
committer | Torbjörn Andersson | 2006-04-06 18:55:39 +0000 |
commit | c07f18650293520928270f58f8441c95ebbf5ee7 (patch) | |
tree | b8fe5395dce57914c727a2ca5fd495d391326bcd | |
parent | 1fa1f9520d1a021de6d16fc8dca523c031ea9f84 (diff) | |
download | scummvm-rg350-c07f18650293520928270f58f8441c95ebbf5ee7.tar.gz scummvm-rg350-c07f18650293520928270f58f8441c95ebbf5ee7.tar.bz2 scummvm-rg350-c07f18650293520928270f58f8441c95ebbf5ee7.zip |
We don't need to convert mono data to stereo: Simply tell the mixer that we're
generating mono data, and let it worry about how to handle it.
svn-id: r21645
-rw-r--r-- | engines/cine/sound_driver.cpp | 6 | ||||
-rw-r--r-- | engines/cine/sound_driver.h | 2 |
2 files changed, 2 insertions, 6 deletions
diff --git a/engines/cine/sound_driver.cpp b/engines/cine/sound_driver.cpp index d0398cb5b1..84b0a1416e 100644 --- a/engines/cine/sound_driver.cpp +++ b/engines/cine/sound_driver.cpp @@ -113,11 +113,7 @@ void AdlibSoundDriver::stopSound() { } int AdlibSoundDriver::readBuffer(int16 *buffer, const int numSamples) { - update(buffer, numSamples / 2); - // convert mono to stereo - for (int i = numSamples / 2 - 1; i >= 0; i--) { - buffer[2 * i] = buffer[2 * i + 1] = buffer[i]; - } + update(buffer, numSamples); return numSamples; } diff --git a/engines/cine/sound_driver.h b/engines/cine/sound_driver.h index e551e65c52..cf1ec68411 100644 --- a/engines/cine/sound_driver.h +++ b/engines/cine/sound_driver.h @@ -91,7 +91,7 @@ public: // AudioStream interface virtual int readBuffer(int16 *buffer, const int numSamples); - virtual bool isStereo() const { return true; } + virtual bool isStereo() const { return false; } virtual bool endOfData() const { return false; } virtual int getRate() const { return _sampleRate; } |