AUDIO: Add default disposeAfterUse value to makeVOCStream again.

This commit is contained in:
Johannes Schickel 2011-10-09 21:01:52 +02:00
parent d4f54a2c97
commit 3e1405b939
4 changed files with 5 additions and 5 deletions

View File

@ -94,7 +94,7 @@ extern byte *loadVOCFromStream(Common::ReadStream &stream, int &size, int &rate)
*
* This does not use any of the looping features of VOC files!
*/
SeekableAudioStream *makeVOCStream(Common::SeekableReadStream *stream, byte flags, DisposeAfterUse::Flag disposeAfterUse);
SeekableAudioStream *makeVOCStream(Common::SeekableReadStream *stream, byte flags, DisposeAfterUse::Flag disposeAfterUse = DisposeAfterUse::NO);
} // End of namespace Audio

View File

@ -255,7 +255,7 @@ public:
Audio::AudioStream *VocSound::makeAudioStream(uint sound) {
assert(_offsets);
_file->seek(_offsets[sound], SEEK_SET);
return Audio::makeVOCStream(_file.get(), _flags, DisposeAfterUse::NO);
return Audio::makeVOCStream(_file.get(), _flags);
}
void VocSound::playSound(uint sound, uint loopSound, Audio::Mixer::SoundType type, Audio::SoundHandle *handle, bool loop, int vol) {

View File

@ -628,7 +628,7 @@ void Sound::startTalkSound(uint32 offset, uint32 b, int mode, Audio::SoundHandle
#endif
break;
default:
input = Audio::makeVOCStream(_sfxFile, Audio::FLAG_UNSIGNED, DisposeAfterUse::NO);
input = Audio::makeVOCStream(_sfxFile, Audio::FLAG_UNSIGNED);
break;
}

View File

@ -591,7 +591,7 @@ void ToucheEngine::res_loadSound(int priority, int num) {
uint32 size;
const uint32 offs = res_getDataOffset(kResourceTypeSound, num, &size);
_fData.seek(offs);
Audio::AudioStream *stream = Audio::makeVOCStream(&_fData, Audio::FLAG_UNSIGNED, DisposeAfterUse::NO);
Audio::AudioStream *stream = Audio::makeVOCStream(&_fData, Audio::FLAG_UNSIGNED);
if (stream) {
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, stream);
}
@ -649,7 +649,7 @@ void ToucheEngine::res_loadSpeechSegment(int num) {
return;
}
_fSpeech[i].seek(offs);
stream = Audio::makeVOCStream(&_fSpeech[i], Audio::FLAG_UNSIGNED, DisposeAfterUse::NO);
stream = Audio::makeVOCStream(&_fSpeech[i], Audio::FLAG_UNSIGNED);
} else {
if (num >= 750) {
num -= 750;