aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorSven Hesse2012-07-08 22:25:51 +0200
committerSven Hesse2012-07-30 01:44:46 +0200
commit25bc7467b444d78c64300af9786f08842de81313 (patch)
tree25be94660fb41cf73883b2387ea5d5bae8c35946 /engines
parent3189729c972b5da1356497e82e08a21c94c8fbec (diff)
downloadscummvm-rg350-25bc7467b444d78c64300af9786f08842de81313.tar.gz
scummvm-rg350-25bc7467b444d78c64300af9786f08842de81313.tar.bz2
scummvm-rg350-25bc7467b444d78c64300af9786f08842de81313.zip
GOB: Use Sound::sampleLoad in PreGob
Diffstat (limited to 'engines')
-rw-r--r--engines/gob/pregob/pregob.cpp12
1 files changed, 1 insertions, 11 deletions
diff --git a/engines/gob/pregob/pregob.cpp b/engines/gob/pregob/pregob.cpp
index 42b5a8fb9c..54eb3c6795 100644
--- a/engines/gob/pregob/pregob.cpp
+++ b/engines/gob/pregob/pregob.cpp
@@ -161,17 +161,7 @@ void PreGob::freeSounds() {
}
bool PreGob::loadSound(SoundDesc &sound, const Common::String &file) const {
- int32 size;
- byte *data = _vm->_dataIO->getFile(file, size);
-
- if (!data || !sound.load(SOUND_SND, data, size)) {
- delete data;
-
- warning("PreGob::loadSound(): Failed to load sound \"%s\"", file.c_str());
- return false;
- }
-
- return true;
+ return _vm->_sound->sampleLoad(&sound, SOUND_SND, file.c_str());
}
void PreGob::playSound(uint sound, int16 frequency, int16 repCount) {