AUDIO: Rename Mixer::playInputStream to playStream

svn-id: r48637
This commit is contained in:
Max Horn 2010-04-12 09:14:17 +00:00
parent 9191b9d528
commit a1840bd573
81 changed files with 145 additions and 145 deletions

View File

@ -118,7 +118,7 @@ void PreAgiEngine::initialize() {
//_sound->initSound();
_speakerStream = new Audio::PCSpeaker(_mixer->getOutputRate());
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_speakerHandle,
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_speakerHandle,
_speakerStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);

View File

@ -487,7 +487,7 @@ int SoundMgr::initSound() {
report("disabled\n");
}
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
return r;
}

View File

@ -313,7 +313,7 @@ void MoviePlayerDXA::startSound() {
if (_bgSoundStream != NULL) {
_vm->_mixer->stopHandle(_bgSound);
_vm->_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_bgSound, _bgSoundStream);
_vm->_mixer->playStream(Audio::Mixer::kSFXSoundType, &_bgSound, _bgSoundStream);
}
}

View File

@ -221,7 +221,7 @@ void AGOSEngine::playModule(uint16 music) {
audioStream = Audio::makeProtrackerStream(&f);
}
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_modHandle, audioStream);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_modHandle, audioStream);
}
void AGOSEngine_Simon1::playMusic(uint16 music, uint16 track) {

View File

@ -242,7 +242,7 @@ Audio::AudioStream *WavSound::makeAudioStream(uint sound) {
void WavSound::playSound(uint sound, uint loopSound, Audio::Mixer::SoundType type, Audio::SoundHandle *handle, bool loop, int vol) {
convertVolume(vol);
_mixer->playInputStream(type, handle, new LoopingAudioStream(this, sound, loopSound, loop), -1, vol);
_mixer->playStream(type, handle, new LoopingAudioStream(this, sound, loopSound, loop), -1, vol);
}
///////////////////////////////////////////////////////////////////////////////
@ -265,7 +265,7 @@ Audio::AudioStream *VocSound::makeAudioStream(uint sound) {
void VocSound::playSound(uint sound, uint loopSound, Audio::Mixer::SoundType type, Audio::SoundHandle *handle, bool loop, int vol) {
convertVolume(vol);
_mixer->playInputStream(type, handle, new LoopingAudioStream(this, sound, loopSound, loop), -1, vol);
_mixer->playStream(type, handle, new LoopingAudioStream(this, sound, loopSound, loop), -1, vol);
}
///////////////////////////////////////////////////////////////////////////////
@ -297,7 +297,7 @@ Audio::AudioStream *RawSound::makeAudioStream(uint sound) {
void RawSound::playSound(uint sound, uint loopSound, Audio::Mixer::SoundType type, Audio::SoundHandle *handle, bool loop, int vol) {
// Sound looping and volume are ignored.
_mixer->playInputStream(type, handle, makeAudioStream(sound));
_mixer->playStream(type, handle, makeAudioStream(sound));
}
///////////////////////////////////////////////////////////////////////////////
@ -324,7 +324,7 @@ public:
void playSound(uint sound, uint loopSound, Audio::Mixer::SoundType type, Audio::SoundHandle *handle, bool loop, int vol = 0) {
convertVolume(vol);
_mixer->playInputStream(type, handle, new LoopingAudioStream(this, sound, loopSound, loop), -1, vol);
_mixer->playStream(type, handle, new LoopingAudioStream(this, sound, loopSound, loop), -1, vol);
}
};
@ -738,7 +738,7 @@ void Sound::playRawData(byte *soundData, uint sound, uint size, uint freq) {
flags = Audio::FLAG_UNSIGNED;
Audio::AudioStream *stream = Audio::makeRawStream(buffer, size, freq, flags);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_effectsHandle, stream);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_effectsHandle, stream);
}
// Feeble Files specific
@ -783,7 +783,7 @@ void Sound::playSoundData(Audio::SoundHandle *handle, byte *soundData, uint soun
convertVolume(vol);
convertPan(pan);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, handle, Audio::makeLoopingAudioStream(sndStream, loop ? 0 : 1), -1, vol, pan);
_mixer->playStream(Audio::Mixer::kSFXSoundType, handle, Audio::makeLoopingAudioStream(sndStream, loop ? 0 : 1), -1, vol, pan);
}
void Sound::stopSfx5() {

View File

@ -245,7 +245,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, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
AdLibSoundDriver::~AdLibSoundDriver() {
@ -802,7 +802,7 @@ void PaulaSound::playMusic() {
debugC(5, kCineDebugSound, "PaulaSound::playMusic()");
_mixer->stopHandle(_moduleHandle);
if (_moduleStream) {
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_moduleHandle, _moduleStream);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_moduleHandle, _moduleStream);
}
}
@ -846,7 +846,7 @@ void PaulaSound::playSoundChannel(int channel, int frequency, uint8 *data, int s
assert(frequency > 0);
frequency = PAULA_FREQ / frequency;
Audio::AudioStream *stream = Audio::makeRawStream(data, size, frequency, 0);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_channelsTable[channel], stream);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_channelsTable[channel], stream);
_mixer->setChannelVolume(_channelsTable[channel], volume * Audio::Mixer::kMaxChannelVolume / 63);
}

View File

@ -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, DisposeAfterUse::NO, true);
_mixer->playStream(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"));

View File

@ -204,7 +204,7 @@ void Sound::playSoundBuffer(Audio::SoundHandle *handle, const SoundSample &buffe
Audio::AudioStream *stream = Audio::makeLoopingAudioStream(
Audio::makeRawStream(buffer._data, buffer._length, buffer._frequency, flags, DisposeAfterUse::NO),
loop ? 0 : 1);
_mixer->playInputStream(soundType, handle, stream, -1, volume);
_mixer->playStream(soundType, handle, stream, -1, volume);
}
void Sound::playSound(const SoundSample *buffer, int volume, bool loop) {

View File

@ -188,7 +188,7 @@ void DrasculaEngine::playFile(const char *fname) {
Audio::AudioStream *sound = Audio::makeRawStream(soundData, soundSize - 64,
11025, Audio::FLAG_UNSIGNED);
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_soundHandle, sound);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_soundHandle, sound);
} else
warning("playFile: Could not open %s", fname);
}

View File

@ -74,7 +74,7 @@ void AdLib::init() {
_pollNotes[i] = 0;
setFreqs();
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_handle,
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_handle,
this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}

View File

@ -66,7 +66,7 @@ bool Infogrames::loadSong(const char *fileName) {
void Infogrames::play() {
if (_song && !_mixer->isSoundHandleActive(_handle)) {
_song->restart();
_mixer->playInputStream(Audio::Mixer::kMusicSoundType,
_mixer->playStream(Audio::Mixer::kMusicSoundType,
&_handle, _song, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO);
}
}

View File

@ -30,7 +30,7 @@ namespace Gob {
PCSpeaker::PCSpeaker(Audio::Mixer &mixer) : _mixer(&mixer) {
_stream = new Audio::PCSpeaker(_mixer->getOutputRate());
_mixer->playInputStream(Audio::Mixer::kSFXSoundType,
_mixer->playStream(Audio::Mixer::kSFXSoundType,
&_handle, _stream, -1, 50, 0, DisposeAfterUse::NO, true);
}

View File

@ -52,7 +52,7 @@ bool Protracker::play(const char *fileName) {
if (!_protrackerStream)
return false;
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_handle,
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_handle,
_protrackerStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO);
return true;

View File

@ -53,7 +53,7 @@ SoundMixer::SoundMixer(Audio::Mixer &mixer, Audio::Mixer::SoundType type) : _mix
_fadeSamples = 0;
_curFadeSamples = 0;
_mixer->playInputStream(type, &_handle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(type, &_handle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
SoundMixer::~SoundMixer() {

View File

@ -519,7 +519,7 @@ bool ROQPlayer::processBlockSoundMono(ROQBlockHeader &blockHeader) {
if (!_audioStream) {
_audioStream = Audio::makeQueuingAudioStream(22050, false);
Audio::SoundHandle sound_handle;
g_system->getMixer()->playInputStream(Audio::Mixer::kPlainSoundType, &sound_handle, _audioStream);
g_system->getMixer()->playStream(Audio::Mixer::kPlainSoundType, &sound_handle, _audioStream);
}
// Create the audio buffer
@ -562,7 +562,7 @@ bool ROQPlayer::processBlockSoundStereo(ROQBlockHeader &blockHeader) {
if (!_audioStream) {
_audioStream = Audio::makeQueuingAudioStream(22050, true);
Audio::SoundHandle sound_handle;
g_system->getMixer()->playInputStream(Audio::Mixer::kPlainSoundType, &sound_handle, _audioStream);
g_system->getMixer()->playStream(Audio::Mixer::kPlainSoundType, &sound_handle, _audioStream);
}
// Create the audio buffer

View File

@ -501,7 +501,7 @@ void VDXPlayer::chunkSound(Common::ReadStream *in) {
if (!_audioStream) {
_audioStream = Audio::makeQueuingAudioStream(22050, false);
Audio::SoundHandle sound_handle;
g_system->getMixer()->playInputStream(Audio::Mixer::kPlainSoundType, &sound_handle, _audioStream);
g_system->getMixer()->playStream(Audio::Mixer::kPlainSoundType, &sound_handle, _audioStream);
}
byte *data = (byte *)malloc(60000);

View File

@ -118,7 +118,7 @@ bool Sound::playVoiceStream(Audio::AudioStream *stream, Audio::SoundHandle *hand
if (h >= kNumChannelHandles)
return false;
_mixer->playInputStream(isSfx ? Audio::Mixer::kSFXSoundType : Audio::Mixer::kSpeechSoundType, &_soundChannels[h], stream, -1, volume);
_mixer->playStream(isSfx ? Audio::Mixer::kSFXSoundType : Audio::Mixer::kSpeechSoundType, &_soundChannels[h], stream, -1, volume);
if (handle)
*handle = _soundChannels[h];

View File

@ -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, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_samplesPerCallback = getRate() / CALLBACKS_PER_SECOND;
_samplesPerCallbackRemainder = getRate() % CALLBACKS_PER_SECOND;

View File

@ -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, DisposeAfterUse::NO);
_mixer->playStream(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, DisposeAfterUse::NO);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_musicHandle, _driver, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO);
}
}

View File

@ -482,7 +482,7 @@ int SoundDigital::playSound(const char *filename, uint8 priority, Audio::Mixer::
if (type == Audio::Mixer::kSpeechSoundType && _vm->heliumMode())
use->stream->setRate(32765);
_mixer->playInputStream(type, &use->handle, makeLoopingAudioStream(use->stream, loop ? 0 : 1), -1, volume);
_mixer->playStream(type, &use->handle, makeLoopingAudioStream(use->stream, loop ? 0 : 1), -1, volume);
return use - _sounds;
}

View File

@ -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, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_countdown = 0xFFFF;
_hardwareChannel[0] = 0xFF;

View File

@ -624,7 +624,7 @@ int Towns_EuphonyDriver::open() {
return MERR_ALREADY_OPEN;
MidiDriver_Emulated::open();
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle,
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle,
this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
return 0;
@ -2977,7 +2977,7 @@ bool TownsPC98_OpnCore::init() {
_prc->init(_percussionData);
}
_mixer->playInputStream(Audio::Mixer::kMusicSoundType,
_mixer->playStream(Audio::Mixer::kMusicSoundType,
&_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_ready = true;
@ -3927,7 +3927,7 @@ void SoundTowns::playSoundEffect(uint8 track) {
_currentSFX = Audio::makeRawStream(sfxPlaybackBuffer, playbackBufferSize,
outputRate, Audio::FLAG_UNSIGNED | Audio::FLAG_LITTLE_ENDIAN);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, _currentSFX);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, _currentSFX);
}
void SoundTowns::beginFadeOut() {
@ -4299,7 +4299,7 @@ int32 SoundTownsPC98_v2::voicePlay(const char *file, Audio::SoundHandle *handle,
_currentSFX = Audio::makeRawStream(sfx, outsize, outputRate,
Audio::FLAG_UNSIGNED | Audio::FLAG_LITTLE_ENDIAN);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_soundChannels[h], _currentSFX);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_soundChannels[h], _currentSFX);
if (handle)
*handle = _soundChannels[h];

View File

@ -649,7 +649,7 @@ void VQAMovie::play() {
}
}
_vm->_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_sound, _stream);
_vm->_mixer->playStream(Audio::Mixer::kSFXSoundType, &_sound, _stream);
Common::EventManager *eventMan = _vm->getEventManager();
for (uint i = 0; i < _header.numFrames; i++) {

View File

@ -96,7 +96,7 @@ void Sound::playSound(const char *soundName, int volume, bool loop, int channel)
Audio::AudioStream *stream = Audio::makeLoopingAudioStream(
Audio::makeRawStream(buffer, bufferSize, 11025, Audio::FLAG_UNSIGNED),
loop ? 0 : 1);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &handle->handle, stream, -1, volume);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &handle->handle, stream, -1, volume);
}
void Sound::playSound(int soundNum) {
@ -151,7 +151,7 @@ void Sound::playVoice(const char *soundName, int volume) {
// Voice format is 8bit mono, unsigned, 11025kHz
Audio::AudioStream *stream = Audio::makeRawStream(buffer, soundStream->size(), 11025, Audio::FLAG_UNSIGNED);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &handle->handle, stream, -1, volume);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &handle->handle, stream, -1, volume);
}
void Sound::pauseVoice() {
@ -267,7 +267,7 @@ void Sound::playDSRSound(int soundIndex, int volume, bool loop) {
_dsrFile.dsrEntries[soundIndex]->uncompSize,
_dsrFile.dsrEntries[soundIndex]->frequency, Audio::FLAG_UNSIGNED),
loop ? 0 : 1);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &handle->handle, stream, -1, volume);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &handle->handle, stream, -1, volume);
/*
// Dump the sound file

View File

@ -175,7 +175,7 @@ bool PmvPlayer::play(const char *filename) {
decompressMovieImage(imageData, *_surface, cmdOffs, pixelOffs, maskOffs, lineSize);
if (firstTime) {
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_audioStreamHandle, _audioStream);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_audioStreamHandle, _audioStream);
soundStartTime = g_system->getMillis();
skipFrames = 0;
firstTime = false;

View File

@ -239,7 +239,7 @@ int16 ScriptFunctions::sfPlaySound(int16 argc, int16 *argv) {
}
if (soundNum > 0) {
SoundResource *soundRes = _vm->_res->getSound(soundNum);
_vm->_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_audioStreamHandle,
_vm->_mixer->playStream(Audio::Mixer::kPlainSoundType, &_audioStreamHandle,
soundRes->getAudioStream(_vm->_soundRate, false));
_vm->_soundEnergyArray = soundRes->getSoundEnergyArray();
_vm->_soundEnergyIndex = 0;
@ -586,7 +586,7 @@ int16 ScriptFunctions::sfPlayVoice(int16 argc, int16 *argv) {
stopSound();
if (soundNum > 0) {
_soundResource = _vm->_res->getSound(soundNum);
_vm->_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_audioStreamHandle,
_vm->_mixer->playStream(Audio::Mixer::kPlainSoundType, &_audioStreamHandle,
_soundResource->getAudioStream(_vm->_soundRate, false));
_vm->_autoStopSound = true;
_soundStarted = true;

View File

@ -140,7 +140,7 @@ Audio::SoundHandle *Sound::playSound(uint16 id, bool mainSoundFile, byte volume,
if (loop)
audStream = Audio::makeLoopingAudioStream((Audio::RewindableAudioStream *)audStream, 0);
_vm->_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &handle->handle, audStream, -1, volume);
_vm->_mixer->playStream(Audio::Mixer::kPlainSoundType, &handle->handle, audStream, -1, volume);
return &handle->handle;
}
@ -308,7 +308,7 @@ void Sound::playSLSTSound(uint16 id, bool fade, bool loop, uint16 volume, int16
// TODO: Handle fading, possibly just raise the volume of the channel in increments?
_vm->_mixer->playInputStream(Audio::Mixer::kPlainSoundType, sndHandle.handle, audStream, -1, volume, convertBalance(balance));
_vm->_mixer->playStream(Audio::Mixer::kPlainSoundType, sndHandle.handle, audStream, -1, volume, convertBalance(balance));
}
void Sound::stopSLSTSound(uint16 index, bool fade) {

View File

@ -191,7 +191,7 @@ void QTPlayer::startAudio() {
if (!_audStream) // No audio/audio not supported
return;
g_system->getMixer()->playInputStream(Audio::Mixer::kPlainSoundType, &_audHandle, _audStream);
g_system->getMixer()->playStream(Audio::Mixer::kPlainSoundType, &_audHandle, _audStream);
}
void QTPlayer::pauseAudio() {

View File

@ -432,7 +432,7 @@ void DosSoundMan_br::playSfx(const char *filename, uint channel, bool looping, i
Channel *ch = &_channels[channel];
Audio::AudioStream *input = loadChannelData(filename, ch, looping);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &ch->handle, input, -1, volume);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &ch->handle, input, -1, volume);
}
void DosSoundMan_br::playMusic() {
@ -509,7 +509,7 @@ void AmigaSoundMan_br::playSfx(const char *filename, uint channel, bool looping,
volume = ch->volume;
}
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &ch->handle, input, -1, volume);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &ch->handle, input, -1, volume);
}
void AmigaSoundMan_br::playMusic() {
@ -531,7 +531,7 @@ void AmigaSoundMan_br::playMusic() {
debugC(3, kDebugAudio, "AmigaSoundMan_ns::playMusic(): created new music stream");
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, _musicStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle, _musicStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false);
}
void AmigaSoundMan_br::stopMusic() {

View File

@ -406,7 +406,7 @@ void AmigaSoundMan_ns::playSfx(const char *filename, uint channel, bool looping,
volume = ch->volume;
}
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &ch->handle, input, -1, volume);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &ch->handle, input, -1, volume);
}
void AmigaSoundMan_ns::stopSfx(uint channel) {
@ -431,7 +431,7 @@ void AmigaSoundMan_ns::playMusic() {
debugC(3, kDebugAudio, "AmigaSoundMan_ns::playMusic(): created new music stream");
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, _musicStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle, _musicStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false);
}
void AmigaSoundMan_ns::stopMusic() {

View File

@ -132,7 +132,7 @@ int AdLibMidiDriver::open() {
adlibSetNoteVolume(i, 0);
adlibTurnNoteOff(i);
}
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
return 0;
}

View File

@ -121,7 +121,7 @@ protected:
void playSoundData(Common::File *f, uint32 size, Audio::SoundHandle *soundHandle) {
Common::MemoryReadStream *tmp = f->readStream(size);
assert(tmp);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, soundHandle, new AudioStreamWrapper(Audio::makeMP3Stream(tmp, DisposeAfterUse::YES)));
_mixer->playStream(Audio::Mixer::kSFXSoundType, soundHandle, new AudioStreamWrapper(Audio::makeMP3Stream(tmp, DisposeAfterUse::YES)));
}
};
#endif
@ -134,7 +134,7 @@ protected:
void playSoundData(Common::File *f, uint32 size, Audio::SoundHandle *soundHandle) {
Common::MemoryReadStream *tmp = f->readStream(size);
assert(tmp);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, soundHandle, new AudioStreamWrapper(Audio::makeVorbisStream(tmp, DisposeAfterUse::YES)));
_mixer->playStream(Audio::Mixer::kSFXSoundType, soundHandle, new AudioStreamWrapper(Audio::makeVorbisStream(tmp, DisposeAfterUse::YES)));
}
};
#endif
@ -147,7 +147,7 @@ protected:
void playSoundData(Common::File *f, uint32 size, Audio::SoundHandle *soundHandle) {
Common::MemoryReadStream *tmp = f->readStream(size);
assert(tmp);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, soundHandle, new AudioStreamWrapper(Audio::makeFLACStream(tmp, DisposeAfterUse::YES)));
_mixer->playStream(Audio::Mixer::kSFXSoundType, soundHandle, new AudioStreamWrapper(Audio::makeFLACStream(tmp, DisposeAfterUse::YES)));
}
};
#endif // #ifdef USE_FLAC
@ -331,7 +331,7 @@ void SBSound::playSoundData(Common::File *f, uint32 size, Audio::SoundHandle *so
Audio::Mixer::SoundType type = (soundHandle == &_speechHandle) ? Audio::Mixer::kSpeechSoundType : Audio::Mixer::kSFXSoundType;
Audio::AudioStream *stream = Audio::makeRawStream(sound, size, 11840, Audio::FLAG_UNSIGNED);
_mixer->playInputStream(type, soundHandle, stream);
_mixer->playStream(type, soundHandle, stream);
}
}
@ -615,7 +615,7 @@ void AmigaSound::playSound(const char *base) {
f->read(soundData, soundSize);
Audio::AudioStream *stream = Audio::makeRawStream(soundData, soundSize, 11025, 0);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, stream);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, stream);
}
}
}
@ -648,7 +648,7 @@ void AmigaSound::playModule(const char *base, int song) {
_mixer->stopHandle(_modHandle);
Audio::AudioStream *stream = loadModule(base, song);
if (stream) {
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_modHandle, stream);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_modHandle, stream);
}
_fanfareCount = 0;
}
@ -657,7 +657,7 @@ void AmigaSound::playPattern(const char *base, int pattern) {
_mixer->stopHandle(_patHandle);
Audio::AudioStream *stream = loadModule(base, -pattern);
if (stream) {
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_patHandle, stream);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_patHandle, stream);
}
}

View File

@ -280,7 +280,7 @@ void Music::play(uint32 resourceId, MusicFlags flags) {
for (int i = 0; i < 2; ++i) {
stream = Audio::SeekableAudioStream::openStreamFile(trackName[i]);
if (stream) {
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle,
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle,
Audio::makeLoopingAudioStream(stream, (flags == MUSIC_LOOP) ? 0 : 1));
_digitalMusic = true;
return;
@ -343,13 +343,13 @@ void Music::play(uint32 resourceId, MusicFlags flags) {
if (audioStream) {
debug(2, "Playing digitized music");
if (loopStart) {
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle,
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle,
new Audio::SubLoopingAudioStream(audioStream,
(flags == MUSIC_LOOP ? 0 : 1),
Audio::Timestamp(0, loopStart, audioStream->getRate()),
audioStream->getLength()));
} else {
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle,
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle,
Audio::makeLoopingAudioStream(audioStream, (flags == MUSIC_LOOP ? 0 : 1)));
}
_digitalMusic = true;

View File

@ -102,7 +102,7 @@ void Sound::playSoundBuffer(Audio::SoundHandle *handle, const SoundBuffer &buffe
}
if (stream != NULL)
_mixer->playInputStream(soundType, handle, Audio::makeLoopingAudioStream(stream, loop ? 0 : 1), -1, volume);
_mixer->playStream(soundType, handle, Audio::makeLoopingAudioStream(stream, loop ? 0 : 1), -1, volume);
}
void Sound::playSound(SoundBuffer &buffer, int volume, bool loop) {

View File

@ -61,7 +61,7 @@ int AudioPlayer::startAudio(uint16 module, uint32 number) {
Audio::AudioStream *audioStream = getAudioStream(number, module, &sampleLen);
if (audioStream) {
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_audioHandle, audioStream);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_audioHandle, audioStream);
return sampleLen;
}

View File

@ -238,7 +238,7 @@ int MidiDriver_AdLib::open(bool isSCI0) {
MidiDriver_Emulated::open();
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, DisposeAfterUse::NO);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, DisposeAfterUse::NO);
return 0;
}

View File

@ -541,7 +541,7 @@ int MidiDriver_Amiga::open() {
MidiDriver_Emulated::open();
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, DisposeAfterUse::NO);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, DisposeAfterUse::NO);
return Common::kNoError;
}

View File

@ -221,7 +221,7 @@ int MidiDriver_PCJr::open(int channels) {
MidiDriver_Emulated::open();
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, DisposeAfterUse::NO);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, _mixer->kMaxChannelVolume, 0, DisposeAfterUse::NO);
return 0;
}

View File

@ -639,7 +639,7 @@ static int sfx_play_iterator_pcm(SongIterator *it, SongHandle handle) {
if (g_system->getMixer()->isReady()) {
Audio::AudioStream *newfeed = it->getAudioStream();
if (newfeed) {
g_system->getMixer()->playInputStream(Audio::Mixer::kSFXSoundType, 0, newfeed);
g_system->getMixer()->playStream(Audio::Mixer::kSFXSoundType, 0, newfeed);
return 1;
}
}

View File

@ -256,11 +256,11 @@ void SciMusic::soundPlay(MusicEntry *pSnd) {
if (pSnd->loop > 1) {
pSnd->pLoopStream = new Audio::LoopingAudioStream(pSnd->pStreamAud,
pSnd->loop, DisposeAfterUse::NO);
_pMixer->playInputStream(pSnd->soundType, &pSnd->hCurrentAud,
_pMixer->playStream(pSnd->soundType, &pSnd->hCurrentAud,
pSnd->pLoopStream, -1, pSnd->volume, 0,
DisposeAfterUse::NO);
} else {
_pMixer->playInputStream(pSnd->soundType, &pSnd->hCurrentAud,
_pMixer->playStream(pSnd->soundType, &pSnd->hCurrentAud,
pSnd->pStreamAud, -1, pSnd->volume, 0,
DisposeAfterUse::NO);
}

View File

@ -169,7 +169,7 @@ void CUP_Player::updateSfx() {
uint8 *soundData = _sfxBuffer + offset;
if (READ_BE_UINT32(soundData) == MKID_BE('DATA')) {
uint32 soundSize = READ_BE_UINT32(soundData + 4);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &sfxChannel->handle,
_mixer->playStream(Audio::Mixer::kSFXSoundType, &sfxChannel->handle,
Audio::makeLoopingAudioStream(
Audio::makeRawStream(soundData + 8, soundSize - 8,
11025, Audio::FLAG_UNSIGNED, DisposeAfterUse::NO),

View File

@ -575,7 +575,7 @@ void SoundHE::playHESound(int soundID, int heOffset, int heChannel, int heFlags)
if (_vm->_game.heversion == 70) {
stream = Audio::makeRawStream(spoolPtr, size, 11025, flags, DisposeAfterUse::NO);
_mixer->playInputStream(type, &_heSoundChannels[heChannel], stream, soundID);
_mixer->playStream(type, &_heSoundChannels[heChannel], stream, soundID);
return;
}
}
@ -671,7 +671,7 @@ void SoundHE::playHESound(int soundID, int heOffset, int heChannel, int heFlags)
} else {
stream = Audio::makeRawStream(ptr + memStream.pos() + heOffset, size - heOffset, rate, flags, DisposeAfterUse::NO);
}
_mixer->playInputStream(type, &_heSoundChannels[heChannel],
_mixer->playStream(type, &_heSoundChannels[heChannel],
Audio::makeLoopingAudioStream(stream, (heFlags & 1) ? 0 : 1), soundID);
}
// Support for sound in Humongous Entertainment games
@ -730,7 +730,7 @@ void SoundHE::playHESound(int soundID, int heOffset, int heChannel, int heFlags)
_mixer->stopHandle(_heSoundChannels[heChannel]);
stream = Audio::makeRawStream(ptr + heOffset + 8, size, rate, flags, DisposeAfterUse::NO);
_mixer->playInputStream(type, &_heSoundChannels[heChannel],
_mixer->playStream(type, &_heSoundChannels[heChannel],
Audio::makeLoopingAudioStream(stream, (heFlags & 1) ? 0 : 1), soundID);
}
// Support for PCM music in 3DO versions of Humongous Entertainment games
@ -751,7 +751,7 @@ void SoundHE::playHESound(int soundID, int heOffset, int heChannel, int heFlags)
_currentMusic = soundID;
stream = Audio::makeRawStream(sound, size, rate, 0);
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, NULL, stream, soundID);
_mixer->playStream(Audio::Mixer::kMusicSoundType, NULL, stream, soundID);
}
else if (READ_BE_UINT32(ptr) == MKID_BE('MIDI')) {
if (_vm->_imuse) {

View File

@ -202,7 +202,7 @@ void IMuseDigital::saveOrLoad(Serializer *ser) {
track->stream = Audio::makeQueuingAudioStream(freq, (track->mixerFlags & kFlagStereo) != 0);
_mixer->playInputStream(track->getType(), &track->mixChanHandle, track->stream, -1, track->getVol(), track->getPan(),
_mixer->playStream(track->getType(), &track->mixChanHandle, track->stream, -1, track->getVol(), track->getPan(),
DisposeAfterUse::YES, false, (track->mixerFlags & kFlagStereo) != 0);
_mixer->pauseHandle(track->mixChanHandle, true);
}

View File

@ -112,7 +112,7 @@ void IMuseDigital::startSound(int soundId, const char *soundName, int soundType,
track->souStreamUsed = (input != 0);
if (track->souStreamUsed) {
_mixer->playInputStream(track->getType(), &track->mixChanHandle, input, -1, track->getVol(), track->getPan(),
_mixer->playStream(track->getType(), &track->mixChanHandle, input, -1, track->getVol(), track->getPan(),
DisposeAfterUse::YES, false, (track->mixerFlags & kFlagStereo) != 0);
} else {
strcpy(track->soundName, soundName);
@ -169,7 +169,7 @@ void IMuseDigital::startSound(int soundId, const char *soundName, int soundType,
}
track->stream = Audio::makeQueuingAudioStream(freq, track->mixerFlags & kFlagStereo);
_mixer->playInputStream(track->getType(), &track->mixChanHandle, track->stream, -1, track->getVol(), track->getPan(),
_mixer->playStream(track->getType(), &track->mixChanHandle, track->stream, -1, track->getVol(), track->getPan(),
DisposeAfterUse::YES, false, (track->mixerFlags & kFlagStereo) != 0);
}
@ -370,7 +370,7 @@ Track *IMuseDigital::cloneToFadeOutTrack(Track *track, int fadeDelay) {
// Create an appendable output buffer
fadeTrack->stream = Audio::makeQueuingAudioStream(_sound->getFreq(fadeTrack->soundDesc), track->mixerFlags & kFlagStereo);
_mixer->playInputStream(track->getType(), &fadeTrack->mixChanHandle, fadeTrack->stream, -1, fadeTrack->getVol(), fadeTrack->getPan(),
_mixer->playStream(track->getType(), &fadeTrack->mixChanHandle, fadeTrack->stream, -1, fadeTrack->getVol(), fadeTrack->getPan(),
DisposeAfterUse::YES, false, (track->mixerFlags & kFlagStereo) != 0);
fadeTrack->used = true;

View File

@ -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, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
Player_MOD::~Player_MOD() {

View File

@ -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, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
Player_NES::~Player_NES() {

View File

@ -726,7 +726,7 @@ Player_PCE::Player_PCE(ScummEngine *scumm, Audio::Mixer *mixer) {
_psg = new PSG_HuC6280(PSG_CLOCK, _sampleRate);
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
Player_PCE::~Player_PCE() {

View File

@ -1263,7 +1263,7 @@ Player_SID::Player_SID(ScummEngine *scumm, Audio::Mixer *mixer) {
initSID();
resetSID();
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
Player_SID::~Player_SID() {

View File

@ -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, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
Player_V2::~Player_V2() {

View File

@ -891,7 +891,7 @@ Player_V2CMS::Player_V2CMS(ScummEngine *scumm, Audio::Mixer *mixer) {
}
}
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
Player_V2CMS::~Player_V2CMS() {

View File

@ -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, DisposeAfterUse::NO);
_mixer->playStream(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, DisposeAfterUse::NO);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle, &_tfmxMusic, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO);
_musicId = nr;
}
}

View File

@ -124,7 +124,7 @@ bool SmushMixer::handleFrame() {
// Stream the data
if (!_channels[i].stream) {
_channels[i].stream = Audio::makeQueuingAudioStream(_channels[i].chan->getRate(), stereo);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_channels[i].handle, _channels[i].stream);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_channels[i].handle, _channels[i].stream);
}
_mixer->setChannelVolume(_channels[i].handle, vol);
_mixer->setChannelBalance(_channels[i].handle, pan);

View File

@ -471,7 +471,7 @@ void SmushPlayer::handleIACT(int32 subSize, Common::SeekableReadStream &b) {
if (!_IACTstream) {
_IACTstream = Audio::makeQueuingAudioStream(22050, true);
_vm->_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_IACTchannel, _IACTstream);
_vm->_mixer->playStream(Audio::Mixer::kSFXSoundType, &_IACTchannel, _IACTstream);
}
_IACTstream->queueBuffer(output_data, 0x1000, DisposeAfterUse::YES, Audio::FLAG_STEREO | Audio::FLAG_16BITS);
@ -1111,7 +1111,7 @@ void SmushPlayer::tryCmpFile(const char *filename) {
strcpy(fname + (i - filename), ".ogg");
if (file->open(fname)) {
_compressedFileMode = true;
_vm->_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_compressedFileSoundHandle, Audio::makeVorbisStream(file, DisposeAfterUse::YES));
_vm->_mixer->playStream(Audio::Mixer::kSFXSoundType, &_compressedFileSoundHandle, Audio::makeVorbisStream(file, DisposeAfterUse::YES));
return;
}
#endif
@ -1120,7 +1120,7 @@ void SmushPlayer::tryCmpFile(const char *filename) {
strcpy(fname + (i - filename), ".mp3");
if (file->open(fname)) {
_compressedFileMode = true;
_vm->_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_compressedFileSoundHandle, Audio::makeMP3Stream(file, DisposeAfterUse::YES));
_vm->_mixer->playStream(Audio::Mixer::kSFXSoundType, &_compressedFileSoundHandle, Audio::makeMP3Stream(file, DisposeAfterUse::YES));
return;
}
#endif

View File

@ -204,7 +204,7 @@ void Sound::playSound(int soundID) {
memcpy(sound, ptr, size);
stream = Audio::makeRawStream(sound, size, rate, Audio::FLAG_UNSIGNED);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID);
_mixer->playStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID);
}
// WORKAROUND bug # 1311447
else if (READ_BE_UINT32(ptr) == 0x460e200d) {
@ -227,7 +227,7 @@ void Sound::playSound(int soundID) {
sound = (byte *)malloc(size);
memcpy(sound, ptr, size);
stream = Audio::makeRawStream(sound, size, rate, Audio::FLAG_UNSIGNED);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID);
_mixer->playStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID);
}
// Support for sampled sound effects in Monkey Island 1 and 2
else if (READ_BE_UINT32(ptr) == MKID_BE('SBL ')) {
@ -299,7 +299,7 @@ void Sound::playSound(int soundID) {
sound = (byte *)malloc(size);
memcpy(sound, ptr + 6, size);
stream = Audio::makeRawStream(sound, size, rate, Audio::FLAG_UNSIGNED);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID);
_mixer->playStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID);
}
else if ((_vm->_game.platform == Common::kPlatformFMTowns && _vm->_game.version == 3) || READ_BE_UINT32(ptr) == MKID_BE('SOUN') || READ_BE_UINT32(ptr) == MKID_BE('TOWS')) {
@ -355,7 +355,7 @@ void Sound::playSound(int soundID) {
} else {
stream = Audio::makeRawStream(sound, waveSize, rate, Audio::FLAG_UNSIGNED);
}
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID, 255, 0);
_mixer->playStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID, 255, 0);
}
break;
case 1:
@ -450,7 +450,7 @@ void Sound::playSound(int soundID) {
stream = plainStream;
}
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID, vol, 0);
_mixer->playStream(Audio::Mixer::kSFXSoundType, NULL, stream, soundID, vol, 0);
}
else {
@ -677,7 +677,7 @@ void Sound::startTalkSound(uint32 offset, uint32 b, int mode, Audio::SoundHandle
_vm->_imuseDigital->startVoice(kTalkSoundID, input);
#endif
} else {
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, handle, input, id);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, handle, input, id);
}
}
}

View File

@ -735,12 +735,12 @@ bool Intro::nextPart(uint16 *&data) {
return false;
vData = _skyDisk->loadFile(*data++);
// HACK: Fill the header with silence. We should
// probably use _skySound instead of calling playInputStream()
// probably use _skySound instead of calling playStream()
// directly, but this will have to do for now.
memset(vData, 127, sizeof(DataFileHeader));
stream = Audio::makeRawStream(vData, _skyDisk->_lastLoadedFileSize, 11025, Audio::FLAG_UNSIGNED);
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_voice, stream, SOUND_VOICE);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_voice, stream, SOUND_VOICE);
return true;
case WAITVOICE:
while (_mixer->isSoundHandleActive(_voice))
@ -756,12 +756,12 @@ bool Intro::nextPart(uint16 *&data) {
case LOOPBG:
_mixer->stopID(SOUND_BG);
stream = Audio::makeRawStream(_bgBuf + 256, _bgSize - 768, 11025, Audio::FLAG_UNSIGNED, DisposeAfterUse::NO);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_bgSfx, Audio::makeLoopingAudioStream(stream, 0), SOUND_BG);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_bgSfx, Audio::makeLoopingAudioStream(stream, 0), SOUND_BG);
return true;
case PLAYBG:
_mixer->stopID(SOUND_BG);
stream = Audio::makeRawStream(_bgBuf + 256, _bgSize - 768, 11025, Audio::FLAG_UNSIGNED, DisposeAfterUse::NO);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_bgSfx, stream, SOUND_BG);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_bgSfx, stream, SOUND_BG);
return true;
case STOPBG:
_mixer->stopID(SOUND_BG);

View File

@ -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, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
AdLibMusic::~AdLibMusic() {

View File

@ -1046,7 +1046,7 @@ void Sound::playSound(uint32 id, byte *sound, uint32 size, Audio::SoundHandle *h
_mixer->stopID(id);
Audio::AudioStream *stream = Audio::makeRawStream(buffer, size, 11025, flags);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, handle, stream, id);
_mixer->playStream(Audio::Mixer::kSFXSoundType, handle, stream, id);
}
void Sound::loadSection(uint8 pSection) {
@ -1126,9 +1126,9 @@ void Sound::playSound(uint16 sound, uint16 volume, uint8 channel) {
}
if (channel == 0)
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_ingameSound0, output, SOUND_CH0, volume, 0);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_ingameSound0, output, SOUND_CH0, volume, 0);
else
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_ingameSound1, output, SOUND_CH1, volume, 0);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_ingameSound1, output, SOUND_CH1, volume, 0);
}
void Sound::fnStartFx(uint32 sound, uint8 channel) {
@ -1252,7 +1252,7 @@ bool Sound::startSpeech(uint16 textNum) {
_mixer->stopID(SOUND_SPEECH);
Audio::AudioStream *stream = Audio::makeRawStream(playBuffer, speechSize, rate, Audio::FLAG_UNSIGNED);
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_ingameSpeech, stream, SOUND_SPEECH);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_ingameSpeech, stream, SOUND_SPEECH);
return true;
}

View File

@ -147,7 +147,7 @@ bool MoviePlayer::load(uint32 id) {
void MoviePlayer::play() {
if (_bgSoundStream) {
_snd->playInputStream(Audio::Mixer::kSFXSoundType, _bgSoundHandle, _bgSoundStream);
_snd->playStream(Audio::Mixer::kSFXSoundType, _bgSoundHandle, _bgSoundStream);
}
bool terminated = false;

View File

@ -238,7 +238,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, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
Music::~Music() {

View File

@ -261,7 +261,7 @@ void Sound::playSample(QueueElement *elem) {
if (SwordEngine::isPsx()) {
uint32 size = READ_LE_UINT32(sampleData);
Audio::AudioStream *audStream = Audio::makeLoopingAudioStream(Audio::makeVagStream(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);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &elem->handle, audStream, elem->id, volume, pan);
} else {
uint32 size = READ_LE_UINT32(sampleData + 0x28);
uint8 flags;
@ -274,7 +274,7 @@ void Sound::playSample(QueueElement *elem) {
Audio::AudioStream *stream = Audio::makeLoopingAudioStream(
Audio::makeRawStream(sampleData + 0x2C, size, 11025, flags, DisposeAfterUse::NO),
(_fxList[elem->id].type == FX_LOOP) ? 0 : 1);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &elem->handle, stream, elem->id, volume, pan);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &elem->handle, stream, elem->id, volume, pan);
}
}
} else
@ -362,14 +362,14 @@ bool Sound::startSpeech(uint16 roomNo, uint16 localNo) {
int16 *data = uncompressSpeech(index + _cowHeaderSize, sampleSize, &size);
if (data) {
stream = Audio::makeRawStream((byte *)data, size, 11025, SPEECH_FLAGS);
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
}
} else if (_cowMode == CowPSX && sampleSize != 0xffffffff) {
_cowFile.seek(index * 2048);
Common::MemoryReadStream *tmp = _cowFile.readStream(sampleSize);
assert(tmp);
stream = Audio::makeVagStream(tmp);
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
// with compressed audio, we can't calculate the wave volume.
// so default to talking.
for (int cnt = 0; cnt < 480; cnt++)
@ -382,7 +382,7 @@ bool Sound::startSpeech(uint16 roomNo, uint16 localNo) {
Common::MemoryReadStream *tmp = _cowFile.readStream(sampleSize);
assert(tmp);
stream = Audio::makeFLACStream(tmp, DisposeAfterUse::YES);
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
// with compressed audio, we can't calculate the wave volume.
// so default to talking.
for (int cnt = 0; cnt < 480; cnt++)
@ -396,7 +396,7 @@ bool Sound::startSpeech(uint16 roomNo, uint16 localNo) {
Common::MemoryReadStream *tmp = _cowFile.readStream(sampleSize);
assert(tmp);
stream = Audio::makeVorbisStream(tmp, DisposeAfterUse::YES);
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
// with compressed audio, we can't calculate the wave volume.
// so default to talking.
for (int cnt = 0; cnt < 480; cnt++)
@ -410,7 +410,7 @@ bool Sound::startSpeech(uint16 roomNo, uint16 localNo) {
Common::MemoryReadStream *tmp = _cowFile.readStream(sampleSize);
assert(tmp);
stream = Audio::makeMP3Stream(tmp, DisposeAfterUse::YES);
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream, SOUND_SPEECH_ID, speechVol, speechPan);
// with compressed audio, we can't calculate the wave volume.
// so default to talking.
for (int cnt = 0; cnt < 480; cnt++)

View File

@ -102,7 +102,7 @@ void MoviePlayer::play(MovieText *movieTexts, uint32 numMovieTexts, uint32 leadI
}
if (_bgSoundStream) {
_snd->playInputStream(Audio::Mixer::kSFXSoundType, _bgSoundHandle, _bgSoundStream);
_snd->playStream(Audio::Mixer::kSFXSoundType, _bgSoundHandle, _bgSoundStream);
}
bool terminated = false;

View File

@ -799,7 +799,7 @@ int32 Sound::playCompSpeech(uint32 speechId, uint8 vol, int8 pan) {
p = -p;
// Start the speech playing
_vm->_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_soundHandleSpeech, input, -1, volume, p);
_vm->_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_soundHandleSpeech, input, -1, volume, p);
return RD_OK;
}

View File

@ -93,7 +93,7 @@ Sound::Sound(Sword2Engine *vm) {
_mixBuffer = NULL;
_mixBufferLen = 0;
_vm->_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_vm->_mixer->playStream(Audio::Mixer::kMusicSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
}
Sound::~Sound() {
@ -343,7 +343,7 @@ int32 Sound::playFx(Audio::SoundHandle *handle, byte *data, uint32 len, uint8 vo
assert(input);
_vm->_mixer->playInputStream(soundType, handle,
_vm->_mixer->playStream(soundType, handle,
Audio::makeLoopingAudioStream(input, loop ? 0 : 1),
-1, vol, pan, DisposeAfterUse::YES, false, isReverseStereo());

View File

@ -433,7 +433,7 @@ Common::Error TeenAgentEngine::run() {
syncSoundSettings();
music->load(1);
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, music, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle, music, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, false);
music->start();
int load_slot = Common::ConfigManager::instance().getInt("save_slot");
@ -925,7 +925,7 @@ void TeenAgentEngine::playSoundNow(byte id) {
//debug(0, "playing %u samples...", size);
Audio::AudioStream *stream = Audio::makeRawStream(data, size, 11025, 0);
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_soundHandle, stream); //dispose is YES by default
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_soundHandle, stream); //dispose is YES by default
}

View File

@ -459,7 +459,7 @@ void BMVPlayer::MovieAudio(int audioOffset, int blobs) {
if (currentSoundFrame == ADVANCE_SOUND) {
if (!audioStarted) {
_vm->_mixer->playInputStream(Audio::Mixer::kSFXSoundType,
_vm->_mixer->playStream(Audio::Mixer::kSFXSoundType,
&_audioHandle, _audioStream, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO);
audioStarted = true;
}

View File

@ -570,7 +570,7 @@ PCMMusicPlayer::PCMMusicPlayer() {
_end = true;
_vm->_mixer->playInputStream(Audio::Mixer::kMusicSoundType,
_vm->_mixer->playStream(Audio::Mixer::kMusicSoundType,
&_handle, this, -1, _volume, 0, DisposeAfterUse::NO, true);
}

View File

@ -117,7 +117,7 @@ bool SoundManager::playSample(int id, Audio::Mixer::SoundType type, Audio::Sound
_vm->_mixer->setVolumeForSoundType(Audio::Mixer::kSpeechSoundType, _vm->_config->_voiceVolume);
// Play the audio stream
_vm->_mixer->playInputStream(type, &curChan.handle, vagStream);
_vm->_mixer->playStream(type, &curChan.handle, vagStream);
} else {
// allocate a buffer
byte *sampleBuf = (byte *)malloc(sampleLen);
@ -158,7 +158,7 @@ bool SoundManager::playSample(int id, Audio::Mixer::SoundType type, Audio::Sound
break;
}
if (sampleStream) {
_vm->_mixer->playInputStream(type, &curChan.handle, sampleStream);
_vm->_mixer->playStream(type, &curChan.handle, sampleStream);
}
}
@ -324,7 +324,7 @@ bool SoundManager::playSample(int id, int sub, bool bLooped, int x, int y, int p
//curChan->timeDuration = (((sampleLen * 64) / 25) * 1000) / (22050 * 2);
// Play it
_vm->_mixer->playInputStream(type, &curChan->handle, sampleStream);
_vm->_mixer->playStream(type, &curChan->handle, sampleStream);
_vm->_mixer->setChannelVolume(curChan->handle, sndVol);
_vm->_mixer->setChannelBalance(curChan->handle, getPan(x));

View File

@ -590,7 +590,7 @@ void ToucheEngine::res_loadSound(int priority, int num) {
_fData.seek(offs);
Audio::AudioStream *stream = Audio::makeVOCStream(&_fData, Audio::FLAG_UNSIGNED);
if (stream) {
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, stream);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, stream);
}
}
}
@ -672,7 +672,7 @@ void ToucheEngine::res_loadSpeechSegment(int num) {
}
if (stream) {
_speechPlaying = true;
_mixer->playInputStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream);
_mixer->playStream(Audio::Mixer::kSpeechSoundType, &_speechHandle, stream);
}
}
}

View File

@ -954,7 +954,7 @@ void TuckerEngine::loadSound(Audio::Mixer::SoundType type, int num, int volume,
if (stream) {
_mixer->stopHandle(*handle);
_mixer->playInputStream(type, handle, Audio::makeLoopingAudioStream(stream, loop ? 0 : 1),
_mixer->playStream(type, handle, Audio::makeLoopingAudioStream(stream, loop ? 0 : 1),
-1, scaleMixerVolume(volume, kMaxSoundVolume));
}
}

View File

@ -616,7 +616,7 @@ void AnimationSequencePlayer::loadSounds(int num) {
if (_soundSeqDataList[num].musicVolume != 0) {
Audio::AudioStream *s;
if ((s = loadSound(_soundSeqDataList[num].musicIndex, kAnimationSoundType8BitsRAW)) != 0) {
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, s, -1, scaleMixerVolume(_soundSeqDataList[num].musicVolume));
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle, s, -1, scaleMixerVolume(_soundSeqDataList[num].musicVolume));
}
}
_soundSeqDataIndex = 0;
@ -631,12 +631,12 @@ void AnimationSequencePlayer::updateSounds() {
switch (p->opcode) {
case 0:
if ((s = loadSound(p->num, kAnimationSoundTypeWAV)) != 0) {
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_soundsHandle[p->index], s, -1, scaleMixerVolume(p->volume));
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_soundsHandle[p->index], s, -1, scaleMixerVolume(p->volume));
}
break;
case 1:
if ((s = loadSound(p->num, kAnimationSoundTypeWAV)) != 0) {
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_soundsHandle[p->index], Audio::makeLoopingAudioStream(s, 0),
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_soundsHandle[p->index], Audio::makeLoopingAudioStream(s, 0),
-1, scaleMixerVolume(p->volume));
}
break;
@ -649,18 +649,18 @@ void AnimationSequencePlayer::updateSounds() {
case 4:
_mixer->stopHandle(_musicHandle);
if ((s = loadSound(p->num, kAnimationSoundType8BitsRAW)) != 0) {
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, s, -1, scaleMixerVolume(p->volume));
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle, s, -1, scaleMixerVolume(p->volume));
}
break;
case 5:
if ((s = loadSound(p->num, kAnimationSoundTypeWAV)) != 0) {
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, s, -1, scaleMixerVolume(p->volume));
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, s, -1, scaleMixerVolume(p->volume));
}
break;
case 6:
_mixer->stopHandle(_musicHandle);
if ((s = loadSound(p->num, kAnimationSoundType16BitsRAW)) != 0) {
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_musicHandle, s, -1, scaleMixerVolume(p->volume));
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_musicHandle, s, -1, scaleMixerVolume(p->volume));
}
break;
default:

View File

@ -245,7 +245,7 @@ bool AviDecoder::loadFile(const char *fileName) {
// Initialize the video stuff too
_audStream = createAudioStream();
if (_audStream)
_mixer->playInputStream(_soundType, _audHandle, _audStream);
_mixer->playStream(_soundType, _audHandle, _audStream);
debug (0, "Frames = %d, Dimensions = %d x %d", _header.totalFrames, _header.width, _header.height);
debug (0, "Frame Rate = %d", getFrameRate());

View File

@ -1068,7 +1068,7 @@ CoktelVideo::State Imd::processFrame(uint16 frame) {
} while (hasNextCmd);
if (startSound && _soundEnabled) {
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_audioHandle, _audioStream);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_audioHandle, _audioStream);
_skipFrames = 0;
_soundStage = 2;
}
@ -2033,7 +2033,7 @@ CoktelVideo::State Vmd::processFrame(uint16 frame) {
if (startSound && _soundEnabled) {
if (_hasSound && _audioStream) {
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_audioHandle, _audioStream);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_audioHandle, _audioStream);
_skipFrames = 0;
_soundStage = 2;
} else

View File

@ -584,7 +584,7 @@ bool SmackerDecoder::decodeNextFrame() {
}
if (!_audioStarted) {
_mixer->playInputStream(_soundType, &_audioHandle, _audioStream, -1, 255);
_mixer->playStream(_soundType, &_audioHandle, _audioStream, -1, 255);
_audioStarted = true;
}
} else {

View File

@ -78,7 +78,7 @@ void AudioCDManager::play(int track, int numLoops, int startFrame, int duration,
repetitions. Finally, -1 means infinitely many
*/
_emulating = true;
_mixer->playInputStream(Mixer::kMusicSoundType, &_handle,
_mixer->playStream(Mixer::kMusicSoundType, &_handle,
makeLoopingAudioStream(stream, start, end, (numLoops < 1) ? numLoops + 1 : numLoops));
} else {
_emulating = false;

View File

@ -212,7 +212,7 @@ void MixerImpl::insertChannel(SoundHandle *handle, Channel *chan) {
*handle = chanHandle;
}
void MixerImpl::playInputStream(
void MixerImpl::playStream(
SoundType type,
SoundHandle *handle,
AudioStream *input,

View File

@ -115,7 +115,7 @@ public:
* not stop this particular stream
* @param reverseStereo a flag indicating whether left and right channels shall be swapped
*/
virtual void playInputStream(
virtual void playStream(
SoundType type,
SoundHandle *handle,
AudioStream *input,

View File

@ -75,7 +75,7 @@ public:
virtual bool isReady() const { return _mixerReady; }
virtual void playInputStream(
virtual void playStream(
SoundType type,
SoundHandle *handle,
AudioStream *input,

View File

@ -918,7 +918,7 @@ int MidiDriver_ADLIB::open() {
adlib_write(0xBD, 0x00);
create_lookup_table();
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
return 0;
}

View File

@ -144,7 +144,7 @@ int MidiDriver_FluidSynth::open() {
MidiDriver_Emulated::open();
// The MT-32 emulator uses kSFXSoundType here. I don't know why.
_mixer->playInputStream(Audio::Mixer::kMusicSoundType, &_handle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kMusicSoundType, &_handle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
return 0;
}

View File

@ -287,7 +287,7 @@ int MidiDriver_MT32::open() {
_initialising = false;
g_system->fillScreen(0);
g_system->updateScreen();
_mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_handle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kSFXSoundType, &_handle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
return 0;
}

View File

@ -587,7 +587,7 @@ int MidiDriver_YM2612::open() {
MidiDriver_Emulated::open();
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
_mixer->playStream(Audio::Mixer::kPlainSoundType, &_mixerSoundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, DisposeAfterUse::NO, true);
return 0;
}