diff options
author | Sven Hesse | 2009-07-29 10:17:44 +0000 |
---|---|---|
committer | Sven Hesse | 2009-07-29 10:17:44 +0000 |
commit | 5213cf9aa21083b6a3f9557a0d75f608913625a2 (patch) | |
tree | a7a6bd8d6ea5de0945b05f4c783458fd06737556 | |
parent | 8bf0424832aaeb55f90af4332e5e02e4d69f58ce (diff) | |
download | scummvm-rg350-5213cf9aa21083b6a3f9557a0d75f608913625a2.tar.gz scummvm-rg350-5213cf9aa21083b6a3f9557a0d75f608913625a2.tar.bz2 scummvm-rg350-5213cf9aa21083b6a3f9557a0d75f608913625a2.zip |
Adding a SoundType parameter to SmackerDecoder, defaulting to kSFXSoundType
svn-id: r42887
-rw-r--r-- | graphics/video/smk_decoder.cpp | 6 | ||||
-rw-r--r-- | graphics/video/smk_decoder.h | 4 |
2 files changed, 6 insertions, 4 deletions
diff --git a/graphics/video/smk_decoder.cpp b/graphics/video/smk_decoder.cpp index 9db8f0c730..8952f553b7 100644 --- a/graphics/video/smk_decoder.cpp +++ b/graphics/video/smk_decoder.cpp @@ -348,8 +348,8 @@ uint32 BigHuffmanTree::getCode(BitStream &bs) { return v; } -SmackerDecoder::SmackerDecoder(Audio::Mixer *mixer) - : _audioStarted(false), _audioStream(0), _mixer(mixer) { +SmackerDecoder::SmackerDecoder(Audio::Mixer *mixer, Audio::Mixer::SoundType soundType) + : _audioStarted(false), _audioStream(0), _mixer(mixer), _soundType(soundType) { } SmackerDecoder::~SmackerDecoder() { @@ -583,7 +583,7 @@ bool SmackerDecoder::decodeNextFrame() { } if (!_audioStarted) { - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_audioHandle, _audioStream, -1, 255); + _mixer->playInputStream(_soundType, &_audioHandle, _audioStream, -1, 255); _audioStarted = true; } } else { diff --git a/graphics/video/smk_decoder.h b/graphics/video/smk_decoder.h index e70d0e6454..e28d85119d 100644 --- a/graphics/video/smk_decoder.h +++ b/graphics/video/smk_decoder.h @@ -55,7 +55,8 @@ class BigHuffmanTree; */ class SmackerDecoder : public VideoDecoder { public: - SmackerDecoder(Audio::Mixer *mixer); + SmackerDecoder(Audio::Mixer *mixer, + Audio::Mixer::SoundType soundType = Audio::Mixer::kSFXSoundType); virtual ~SmackerDecoder(); int getHeight(); @@ -113,6 +114,7 @@ private: // The RGB palette byte *_palette; + Audio::Mixer::SoundType _soundType; Audio::Mixer *_mixer; bool _audioStarted; Audio::AppendableAudioStream *_audioStream; |