diff options
Diffstat (limited to 'engines')
35 files changed, 41 insertions, 41 deletions
diff --git a/engines/agi/preagi.cpp b/engines/agi/preagi.cpp index 19ae08ab32..67583d9def 100644 --- a/engines/agi/preagi.cpp +++ b/engines/agi/preagi.cpp @@ -118,7 +118,7 @@ void PreAgiEngine::initialize() { _speakerStream = new Audio::PCSpeaker(_mixer->getOutputRate()); _mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_speakerHandle, - _speakerStream, -1, 255, 0, false, true); + _speakerStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); //_timer->installTimerProc(agiTimerFunctionLow, 10 * 1000, NULL); diff --git a/engines/agi/sound.cpp b/engines/agi/sound.cpp index a0d750199b..53777d4dd2 100644 --- a/engines/agi/sound.cpp +++ b/engines/agi/sound.cpp @@ -485,7 +485,7 @@ int SoundMgr::initSound() { report("disabled\n"); } - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); return r; } diff --git a/engines/cine/sound.cpp b/engines/cine/sound.cpp index 65b384ac7d..287b7a605e 100644 --- a/engines/cine/sound.cpp +++ b/engines/cine/sound.cpp @@ -244,7 +244,7 @@ AdlibSoundDriver::AdlibSoundDriver(Audio::Mixer *mixer) memset(_channelsVolumeTable, 0, sizeof(_channelsVolumeTable)); memset(_instrumentsTable, 0, sizeof(_instrumentsTable)); initCard(); - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } AdlibSoundDriver::~AdlibSoundDriver() { diff --git a/engines/cruise/sound.cpp b/engines/cruise/sound.cpp index 4985dd3ef8..3a40e35ed3 100644 --- a/engines/cruise/sound.cpp +++ b/engines/cruise/sound.cpp @@ -298,7 +298,7 @@ AdlibSoundDriver::AdlibSoundDriver(Audio::Mixer *mixer) } memset(_instrumentsTable, 0, sizeof(_instrumentsTable)); initCard(); - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); _musicVolume = ConfMan.getBool("music_mute") ? 0 : MIN(255, ConfMan.getInt("music_volume")); _sfxVolume = ConfMan.getBool("sfx_mute") ? 0 : MIN(255, ConfMan.getInt("sfx_volume")); diff --git a/engines/gob/global.h b/engines/gob/global.h index c86e321737..4fce5952eb 100644 --- a/engines/gob/global.h +++ b/engines/gob/global.h @@ -45,8 +45,8 @@ namespace Gob { #define INTERSOUND_FLAG 0x0002 #define SPEAKER_FLAG 0x0001 -#define NO 0 -#define YES 1 +//#define NO 0 +//#define YES 1 #define UNDEF 2 #define F1_KEY 0x3B00 diff --git a/engines/gob/sound/adlib.cpp b/engines/gob/sound/adlib.cpp index f925fc5b47..7566a9f8c7 100644 --- a/engines/gob/sound/adlib.cpp +++ b/engines/gob/sound/adlib.cpp @@ -75,7 +75,7 @@ void AdLib::init() { setFreqs(); _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_handle, - this, -1, 255, 0, false, true); + this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } int AdLib::readBuffer(int16 *buffer, const int numSamples) { diff --git a/engines/gob/sound/infogrames.cpp b/engines/gob/sound/infogrames.cpp index c955dba43f..7c338a5544 100644 --- a/engines/gob/sound/infogrames.cpp +++ b/engines/gob/sound/infogrames.cpp @@ -67,7 +67,7 @@ void Infogrames::play() { if (_song && !_mixer->isSoundHandleActive(_handle)) { _song->restart(); _mixer->playInputStream(Audio::Mixer::kMusicSoundType, - &_handle, _song, -1, 255, 0, false); + &_handle, _song, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO); } } diff --git a/engines/gob/sound/pcspeaker.cpp b/engines/gob/sound/pcspeaker.cpp index 0d1fc0a6db..43b54c5aea 100644 --- a/engines/gob/sound/pcspeaker.cpp +++ b/engines/gob/sound/pcspeaker.cpp @@ -31,7 +31,7 @@ PCSpeaker::PCSpeaker(Audio::Mixer &mixer) : _mixer(&mixer) { _stream = new Audio::PCSpeaker(_mixer->getOutputRate()); _mixer->playInputStream(Audio::Mixer::kSFXSoundType, - &_handle, _stream, -1, 50, 0, false, true); + &_handle, _stream, -1, 50, 0, DisposeAfterUse::NO, true); } PCSpeaker::~PCSpeaker() { diff --git a/engines/gob/sound/protracker.cpp b/engines/gob/sound/protracker.cpp index 3e33cfd494..9630610fa3 100644 --- a/engines/gob/sound/protracker.cpp +++ b/engines/gob/sound/protracker.cpp @@ -53,7 +53,7 @@ bool Protracker::play(const char *fileName) { return false; _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_handle, - _protrackerStream, -1, 255, 0, false); + _protrackerStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO); return true; } diff --git a/engines/gob/sound/soundmixer.cpp b/engines/gob/sound/soundmixer.cpp index eb6d7882f0..bf7d85d544 100644 --- a/engines/gob/sound/soundmixer.cpp +++ b/engines/gob/sound/soundmixer.cpp @@ -51,7 +51,7 @@ SoundMixer::SoundMixer(Audio::Mixer &mixer, Audio::Mixer::SoundType type) : _mix _fadeSamples = 0; _curFadeSamples = 0; - _mixer->playInputStream(type, &_handle, this, -1, 255, 0, false, true); + _mixer->playInputStream(type, &_handle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } SoundMixer::~SoundMixer() { diff --git a/engines/kyra/sound_adlib.cpp b/engines/kyra/sound_adlib.cpp index 3da1204a5d..51f5ba9392 100644 --- a/engines/kyra/sound_adlib.cpp +++ b/engines/kyra/sound_adlib.cpp @@ -451,7 +451,7 @@ AdlibDriver::AdlibDriver(Audio::Mixer *mixer, bool v2) { // is used by SFX or music, and then adjust the volume accordingly. Since Kyrandia 2 supports // different volumes for SFX and music, looking at the disasm and checking how the original does it // would be a good idea. - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); _samplesPerCallback = getRate() / CALLBACKS_PER_SECOND; _samplesPerCallbackRemainder = getRate() % CALLBACKS_PER_SECOND; diff --git a/engines/kyra/sound_amiga.cpp b/engines/kyra/sound_amiga.cpp index 38565ad023..751c5eba88 100644 --- a/engines/kyra/sound_amiga.cpp +++ b/engines/kyra/sound_amiga.cpp @@ -154,7 +154,7 @@ void SoundAmiga::playTrack(uint8 track) { _driver->setVolume(volume); _driver->setTempo(tempo << 4); if (!_mixer->isSoundHandleActive(_musicHandle)) - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_musicHandle, _driver, -1, Audio::Mixer::kMaxChannelVolume, 0, false); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_musicHandle, _driver, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO); } } else if (track == 0) _driver->stopMusic(); @@ -215,7 +215,7 @@ void SoundAmiga::playSoundEffect(uint8 track) { if (_sfxEnabled && sfx) { const bool success = _driver->playNote(sfx->note, sfx->patch, sfx->duration, sfx->volume, pan); if (success && !_mixer->isSoundHandleActive(_musicHandle)) - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_musicHandle, _driver, -1, Audio::Mixer::kMaxChannelVolume, 0, false); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_musicHandle, _driver, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO); } } diff --git a/engines/kyra/sound_pcspk.cpp b/engines/kyra/sound_pcspk.cpp index 8da356072a..b694c8ceb8 100644 --- a/engines/kyra/sound_pcspk.cpp +++ b/engines/kyra/sound_pcspk.cpp @@ -41,7 +41,7 @@ MidiDriver_PCSpeaker::MidiDriver_PCSpeaker(Audio::Mixer *mixer) _speaker = new Audio::PCSpeaker(_rate); assert(_speaker); - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); _countdown = 0xFFFF; _hardwareChannel[0] = 0xFF; diff --git a/engines/kyra/sound_towns.cpp b/engines/kyra/sound_towns.cpp index 8e24d6f47b..ff4ba7e120 100644 --- a/engines/kyra/sound_towns.cpp +++ b/engines/kyra/sound_towns.cpp @@ -624,7 +624,7 @@ int Towns_EuphonyDriver::open() { MidiDriver_Emulated::open(); _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, - this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); return 0; } @@ -2977,7 +2977,7 @@ bool TownsPC98_OpnCore::init() { } _mixer->playInputStream(Audio::Mixer::kMusicSoundType, - &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); _ready = true; diff --git a/engines/parallaction/sound_br.cpp b/engines/parallaction/sound_br.cpp index c0e3f3b24a..761c5796b2 100644 --- a/engines/parallaction/sound_br.cpp +++ b/engines/parallaction/sound_br.cpp @@ -536,7 +536,7 @@ void AmigaSoundMan_br::playMusic() { debugC(3, kDebugAudio, "AmigaSoundMan_ns::playMusic(): created new music stream"); - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, _musicStream, -1, 255, 0, false, false); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, _musicStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false); } void AmigaSoundMan_br::stopMusic() { diff --git a/engines/parallaction/sound_ns.cpp b/engines/parallaction/sound_ns.cpp index b2336c55d9..7177ef60b9 100644 --- a/engines/parallaction/sound_ns.cpp +++ b/engines/parallaction/sound_ns.cpp @@ -430,7 +430,7 @@ void AmigaSoundMan_ns::playMusic() { debugC(3, kDebugAudio, "AmigaSoundMan_ns::playMusic(): created new music stream"); - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, _musicStream, -1, 255, 0, false, false); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, _musicStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false); } void AmigaSoundMan_ns::stopMusic() { diff --git a/engines/queen/midiadlib.cpp b/engines/queen/midiadlib.cpp index 732c93ecd2..6c6b39c6bc 100644 --- a/engines/queen/midiadlib.cpp +++ b/engines/queen/midiadlib.cpp @@ -132,7 +132,7 @@ int AdlibMidiDriver::open() { adlibSetNoteVolume(i, 0); adlibTurnNoteOff(i); } - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); return 0; } diff --git a/engines/saga/sound.cpp b/engines/saga/sound.cpp index 80a3504e35..e611cd4bdc 100644 --- a/engines/saga/sound.cpp +++ b/engines/saga/sound.cpp @@ -103,7 +103,7 @@ void Sound::playSoundBuffer(Audio::SoundHandle *handle, SoundBuffer &buffer, int } if (stream != NULL) - _mixer->playInputStream(soundType, handle, stream, -1, volume, 0, true, false); + _mixer->playInputStream(soundType, handle, stream, -1, volume, 0, DisposeAfterUse::YES, false); } } diff --git a/engines/sci/sound/music.cpp b/engines/sci/sound/music.cpp index d84360d1fe..e1ac79f4c9 100644 --- a/engines/sci/sound/music.cpp +++ b/engines/sci/sound/music.cpp @@ -388,11 +388,11 @@ void SciMusic::soundPlay(MusicEntry *pSnd) { ); _pMixer->playInputStream(pSnd->soundType, &pSnd->hCurrentAud, pSnd->pLoopStream, -1, pSnd->volume, 0, - false); + DisposeAfterUse::NO); } else { _pMixer->playInputStream(pSnd->soundType, &pSnd->hCurrentAud, pSnd->pStreamAud, -1, pSnd->volume, 0, - false); + DisposeAfterUse::NO); } } else { _mutex.lock(); diff --git a/engines/sci/sound/softseq/adlib.cpp b/engines/sci/sound/softseq/adlib.cpp index 6f73b45650..7cfcf0cbaf 100644 --- a/engines/sci/sound/softseq/adlib.cpp +++ b/engines/sci/sound/softseq/adlib.cpp @@ -229,7 +229,7 @@ int MidiDriver_Adlib::open(bool isSCI0) { MidiDriver_Emulated::open(); - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, false); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, DisposeAfterUse::NO); return 0; } diff --git a/engines/sci/sound/softseq/amiga.cpp b/engines/sci/sound/softseq/amiga.cpp index 452768901a..1042d98422 100644 --- a/engines/sci/sound/softseq/amiga.cpp +++ b/engines/sci/sound/softseq/amiga.cpp @@ -541,7 +541,7 @@ int MidiDriver_Amiga::open() { MidiDriver_Emulated::open(); - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, false); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, DisposeAfterUse::NO); return Common::kNoError; } diff --git a/engines/scumm/player_mod.cpp b/engines/scumm/player_mod.cpp index 8e2ae585da..b148818d81 100644 --- a/engines/scumm/player_mod.cpp +++ b/engines/scumm/player_mod.cpp @@ -49,7 +49,7 @@ Player_MOD::Player_MOD(Audio::Mixer *mixer) { _playproc = NULL; _playparam = NULL; - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } Player_MOD::~Player_MOD() { diff --git a/engines/scumm/player_nes.cpp b/engines/scumm/player_nes.cpp index 539dbc61a9..0aaa8f9895 100644 --- a/engines/scumm/player_nes.cpp +++ b/engines/scumm/player_nes.cpp @@ -621,7 +621,7 @@ Player_NES::Player_NES(ScummEngine *scumm, Audio::Mixer *mixer) { APU_writeControl(0); - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } Player_NES::~Player_NES() { diff --git a/engines/scumm/player_pce.cpp b/engines/scumm/player_pce.cpp index f4d44fea22..5e8a0cdca5 100644 --- a/engines/scumm/player_pce.cpp +++ b/engines/scumm/player_pce.cpp @@ -725,7 +725,7 @@ Player_PCE::Player_PCE(ScummEngine *scumm, Audio::Mixer *mixer) { _psg = new PSG_HuC6280(PSG_CLOCK, _sample_rate); - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } Player_PCE::~Player_PCE() { diff --git a/engines/scumm/player_sid.cpp b/engines/scumm/player_sid.cpp index 8971bb8436..0d7bb380b9 100644 --- a/engines/scumm/player_sid.cpp +++ b/engines/scumm/player_sid.cpp @@ -1261,7 +1261,7 @@ Player_SID::Player_SID(ScummEngine *scumm, Audio::Mixer *mixer) { initSID(); resetSID(); - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } Player_SID::~Player_SID() { diff --git a/engines/scumm/player_v2.cpp b/engines/scumm/player_v2.cpp index 200ad4ad6d..06e9e929c6 100644 --- a/engines/scumm/player_v2.cpp +++ b/engines/scumm/player_v2.cpp @@ -366,7 +366,7 @@ Player_V2::Player_V2(ScummEngine *scumm, Audio::Mixer *mixer, bool pcjr) { set_pcjr(pcjr); setMusicVolume(255); - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } Player_V2::~Player_V2() { diff --git a/engines/scumm/player_v2cms.cpp b/engines/scumm/player_v2cms.cpp index 9f14a3587c..4c993b7c2d 100644 --- a/engines/scumm/player_v2cms.cpp +++ b/engines/scumm/player_v2cms.cpp @@ -893,7 +893,7 @@ Player_V2CMS::Player_V2CMS(ScummEngine *scumm, Audio::Mixer *mixer) { } } - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } Player_V2CMS::~Player_V2CMS() { diff --git a/engines/scumm/player_v4a.cpp b/engines/scumm/player_v4a.cpp index 7ee4ed980a..ad5d5c0a5b 100644 --- a/engines/scumm/player_v4a.cpp +++ b/engines/scumm/player_v4a.cpp @@ -154,7 +154,7 @@ void Player_V4A::startSound(int nr) { // the Tfmx-player never "ends" the output by itself, so this should be threadsafe if (!_mixer->isSoundHandleActive(_sfxHandle)) - _mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, &_tfmxSfx, -1, Audio::Mixer::kMaxChannelVolume, 0, false); + _mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, &_tfmxSfx, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO); } else { // Song debug(3, "player_v4a: play %d: song %i - %02X", nr, index, type); @@ -166,7 +166,7 @@ void Player_V4A::startSound(int nr) { // the Tfmx-player never "ends" the output by itself, so this should be threadsafe if (!_mixer->isSoundHandleActive(_musicHandle)) - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, &_tfmxMusic, -1, Audio::Mixer::kMaxChannelVolume, 0, false); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, &_tfmxMusic, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO); _musicId = nr; } } diff --git a/engines/sky/music/adlibmusic.cpp b/engines/sky/music/adlibmusic.cpp index da04b4fc95..74735b30d8 100644 --- a/engines/sky/music/adlibmusic.cpp +++ b/engines/sky/music/adlibmusic.cpp @@ -40,7 +40,7 @@ AdlibMusic::AdlibMusic(Audio::Mixer *pMixer, Disk *pDisk) : MusicBase(pDisk) { _opl = makeAdlibOPL(_sampleRate); - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } AdlibMusic::~AdlibMusic() { diff --git a/engines/sword1/music.cpp b/engines/sword1/music.cpp index c46f980cd0..de5906713e 100644 --- a/engines/sword1/music.cpp +++ b/engines/sword1/music.cpp @@ -237,7 +237,7 @@ Music::Music(Audio::Mixer *pMixer) { _converter[0] = NULL; _converter[1] = NULL; _volumeL = _volumeR = 192; - _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } Music::~Music() { diff --git a/engines/sword1/sound.cpp b/engines/sword1/sound.cpp index 31439d587d..98b87d56ea 100644 --- a/engines/sword1/sound.cpp +++ b/engines/sword1/sound.cpp @@ -259,7 +259,7 @@ void Sound::playSample(QueueElement *elem) { if (SwordEngine::isPsx()) { ; uint32 size = READ_LE_UINT32(sampleData); Audio::AudioStream *audStream = Audio::makeLoopingAudioStream(new Audio::VagStream(new Common::MemoryReadStream(sampleData + 4, size-4)), (_fxList[elem->id].type == FX_LOOP) ? 0 : 1); - _mixer->playInputStream(Audio::Mixer::kSFXSoundType, &elem->handle, audStream, elem->id, volume, pan, false, false, false); + _mixer->playInputStream(Audio::Mixer::kSFXSoundType, &elem->handle, audStream, elem->id, volume, pan, DisposeAfterUse::NO, false, false); } else { uint32 size = READ_LE_UINT32(sampleData + 0x28); uint8 flags; diff --git a/engines/sword2/sound.cpp b/engines/sword2/sound.cpp index 213f3e7c83..224bc66a95 100644 --- a/engines/sword2/sound.cpp +++ b/engines/sword2/sound.cpp @@ -90,7 +90,7 @@ Sound::Sound(Sword2Engine *vm) { _mixBuffer = NULL; _mixBufferLen = 0; - _vm->_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true); + _vm->_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true); } Sound::~Sound() { @@ -342,7 +342,7 @@ int32 Sound::playFx(Audio::SoundHandle *handle, byte *data, uint32 len, uint8 vo _vm->_mixer->playInputStream(soundType, handle, Audio::makeLoopingAudioStream(input, loop ? 0 : 1), - -1, vol, pan, true, false, isReverseStereo()); + -1, vol, pan, DisposeAfterUse::YES, false, isReverseStereo()); return RD_OK; } diff --git a/engines/teenagent/teenagent.cpp b/engines/teenagent/teenagent.cpp index e71812c99c..9b446ff120 100644 --- a/engines/teenagent/teenagent.cpp +++ b/engines/teenagent/teenagent.cpp @@ -433,7 +433,7 @@ Common::Error TeenAgentEngine::run() { syncSoundSettings(); music->load(1); - _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, music, -1, 255, 0, true, false); + _mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, music, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false); music->start(); int load_slot = Common::ConfigManager::instance().getInt("save_slot"); diff --git a/engines/tinsel/bmv.cpp b/engines/tinsel/bmv.cpp index 0bb13c2fab..85cc9bc7f2 100644 --- a/engines/tinsel/bmv.cpp +++ b/engines/tinsel/bmv.cpp @@ -458,7 +458,7 @@ void BMVPlayer::MovieAudio(int audioOffset, int blobs) { if (currentSoundFrame == ADVANCE_SOUND) { if (!audioStarted) { _vm->_mixer->playInputStream(Audio::Mixer::kSFXSoundType, - &_audioHandle, _audioStream, -1, Audio::Mixer::kMaxChannelVolume, 0, false); + &_audioHandle, _audioStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO); audioStarted = true; } } diff --git a/engines/tinsel/music.cpp b/engines/tinsel/music.cpp index d38739d46a..7eee6b0aa8 100644 --- a/engines/tinsel/music.cpp +++ b/engines/tinsel/music.cpp @@ -571,7 +571,7 @@ PCMMusicPlayer::PCMMusicPlayer() { _end = true; _vm->_mixer->playInputStream(Audio::Mixer::kMusicSoundType, - &_handle, this, -1, _volume, 0, false, true); + &_handle, this, -1, _volume, 0, DisposeAfterUse::NO, true); } PCMMusicPlayer::~PCMMusicPlayer() { |