diff options
author | JenniBee | 2018-05-16 00:36:21 -0400 |
---|---|---|
committer | Adrian Frühwirth | 2018-05-17 18:08:18 +0000 |
commit | 5090b6cbbbbabad7443ee653cabd38594c3186ca (patch) | |
tree | 3ec1a23fdac32ef3f397ed6f8034fc7da97e4b9d /engines/wintermute/base/sound | |
parent | fa6a9280b215bef7ad36fcaffef02a267be5be2f (diff) | |
download | scummvm-rg350-5090b6cbbbbabad7443ee653cabd38594c3186ca.tar.gz scummvm-rg350-5090b6cbbbbabad7443ee653cabd38594c3186ca.tar.bz2 scummvm-rg350-5090b6cbbbbabad7443ee653cabd38594c3186ca.zip |
WINTERMUTE: Add flag for games using low-spec resources.
Diffstat (limited to 'engines/wintermute/base/sound')
-rw-r--r-- | engines/wintermute/base/sound/base_sound_buffer.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/engines/wintermute/base/sound/base_sound_buffer.cpp b/engines/wintermute/base/sound/base_sound_buffer.cpp index 5fdac12cef..adcdd828a1 100644 --- a/engines/wintermute/base/sound/base_sound_buffer.cpp +++ b/engines/wintermute/base/sound/base_sound_buffer.cpp @@ -33,7 +33,9 @@ #include "engines/wintermute/wintermute.h" #include "audio/audiostream.h" #include "audio/mixer.h" +#ifdef USE_VORBIS #include "audio/decoders/vorbis.h" +#endif #include "audio/decoders/wave.h" #include "audio/decoders/raw.h" #include "common/system.h" @@ -102,9 +104,12 @@ bool BaseSoundBuffer::loadFromFile(const Common::String &filename, bool forceRel } Common::String strFilename(filename); strFilename.toLowercase(); - if (strFilename.hasSuffix(".ogg")) { - _stream = Audio::makeVorbisStream(_file, DisposeAfterUse::YES); - } else if (strFilename.hasSuffix(".wav")) { + #ifdef USE_VORBIS + if (strFilename.hasSuffix(".ogg")) { + _stream = Audio::makeVorbisStream(_file, DisposeAfterUse::YES); + } + #endif + if (strFilename.hasSuffix(".wav")) { int waveSize, waveRate; byte waveFlags; uint16 waveType; |