diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/kyra/sound_towns.cpp | 4 | ||||
-rw-r--r-- | engines/made/resource.cpp | 2 | ||||
-rw-r--r-- | engines/mohawk/sound.cpp | 4 | ||||
-rw-r--r-- | engines/mohawk/video/qt_player.cpp | 2 | ||||
-rw-r--r-- | engines/parallaction/sound_br.cpp | 4 | ||||
-rw-r--r-- | engines/parallaction/sound_ns.cpp | 2 | ||||
-rw-r--r-- | engines/saga/music.cpp | 4 | ||||
-rw-r--r-- | engines/sci/sound/audio.cpp | 2 | ||||
-rw-r--r-- | engines/sci/sound/iterator/iterator.cpp | 2 | ||||
-rw-r--r-- | engines/sci/sound/music.cpp | 2 | ||||
-rw-r--r-- | engines/scumm/he/cup_player_he.cpp | 2 | ||||
-rw-r--r-- | engines/scumm/he/sound_he.cpp | 4 | ||||
-rw-r--r-- | engines/scumm/player_mod.cpp | 2 | ||||
-rw-r--r-- | engines/tucker/sequences.cpp | 2 |
14 files changed, 19 insertions, 19 deletions
diff --git a/engines/kyra/sound_towns.cpp b/engines/kyra/sound_towns.cpp index ff4ba7e120..2c42e7fb2b 100644 --- a/engines/kyra/sound_towns.cpp +++ b/engines/kyra/sound_towns.cpp @@ -3924,7 +3924,7 @@ void SoundTowns::playSoundEffect(uint8 track) { uint32 outputRate = uint32(11025 * calculatePhaseStep(note, sfxRootNoteOffs, sfxRate, 11025, 0x2000)); - _currentSFX = Audio::makeLinearInputStream(sfxPlaybackBuffer, playbackBufferSize, + _currentSFX = Audio::makeRawMemoryStream(sfxPlaybackBuffer, playbackBufferSize, outputRate, Audio::Mixer::FLAG_UNSIGNED | Audio::Mixer::FLAG_LITTLE_ENDIAN | Audio::Mixer::FLAG_AUTOFREE, 0, 0); _mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_sfxHandle, _currentSFX); } @@ -4296,7 +4296,7 @@ int32 SoundTownsPC98_v2::voicePlay(const char *file, Audio::SoundHandle *handle, uint32 outputRate = uint32(11025 * SoundTowns::calculatePhaseStep(0x3c, 0x3c, sfxRate, 11025, 0x2000)); - _currentSFX = Audio::makeLinearInputStream(sfx, outsize, outputRate, + _currentSFX = Audio::makeRawMemoryStream(sfx, outsize, outputRate, Audio::Mixer::FLAG_UNSIGNED | Audio::Mixer::FLAG_LITTLE_ENDIAN | Audio::Mixer::FLAG_AUTOFREE, 0, 0); _mixer->playInputStream(Audio::Mixer::kSFXSoundType, &_soundChannels[h], _currentSFX); if (handle) diff --git a/engines/made/resource.cpp b/engines/made/resource.cpp index 22e3149b12..2913d23b27 100644 --- a/engines/made/resource.cpp +++ b/engines/made/resource.cpp @@ -264,7 +264,7 @@ Audio::AudioStream *SoundResource::getAudioStream(int soundRate, bool loop) { if (loop) flags |= Audio::Mixer::FLAG_LOOP; - return Audio::makeLinearInputStream(_soundData, _soundSize, soundRate, flags, 0, 0); + return Audio::makeRawMemoryStream(_soundData, _soundSize, soundRate, flags, 0, 0); } void SoundResourceV1::load(byte *source, int size) { diff --git a/engines/mohawk/sound.cpp b/engines/mohawk/sound.cpp index fd37bbdfee..db40555dc9 100644 --- a/engines/mohawk/sound.cpp +++ b/engines/mohawk/sound.cpp @@ -439,7 +439,7 @@ Audio::AudioStream *Sound::makeMohawkWaveStream(Common::SeekableReadStream *stre flags |= Audio::Mixer::FLAG_STEREO; if (data_chunk.loop == 0xFFFF || loop) flags |= Audio::Mixer::FLAG_LOOP; - return Audio::makeLinearInputStream(data_chunk.audio_data, data_chunk.size, data_chunk.sample_rate, flags, data_chunk.loopStart, data_chunk.loopEnd); + return Audio::makeRawMemoryStream(data_chunk.audio_data, data_chunk.size, data_chunk.sample_rate, flags, data_chunk.loopStart, data_chunk.loopEnd); } else if (data_chunk.encoding == kCodecADPCM) { Common::MemoryReadStream *dataStream = new Common::MemoryReadStream(data_chunk.audio_data, data_chunk.size, DisposeAfterUse::YES); uint32 blockAlign = data_chunk.channels * data_chunk.bitsPerSample / 8; @@ -485,7 +485,7 @@ Audio::AudioStream *Sound::makeOldMohawkWaveStream(Common::SeekableReadStream *s if (loop) flags |= Audio::Mixer::FLAG_LOOP; - return Audio::makeLinearInputStream(data, size, rate, flags, 0, 0); + return Audio::makeRawMemoryStream(data, size, rate, flags, 0, 0); } SndHandle *Sound::getHandle() { diff --git a/engines/mohawk/video/qt_player.cpp b/engines/mohawk/video/qt_player.cpp index 9f95e20c8e..2cb1ed364c 100644 --- a/engines/mohawk/video/qt_player.cpp +++ b/engines/mohawk/video/qt_player.cpp @@ -1169,7 +1169,7 @@ Audio::AudioStream *QTPlayer::createAudioStream(Common::SeekableReadStream *stre byte *data = (byte *)malloc(dataSize); stream->read(data, dataSize); delete stream; - return Audio::makeLinearInputStream(data, dataSize, _streams[_audioStreamIndex]->sample_rate, flags, 0, 0); + return Audio::makeRawMemoryStream(data, dataSize, _streams[_audioStreamIndex]->sample_rate, flags, 0, 0); } else if (_streams[_audioStreamIndex]->codec_tag == MKID_BE('ima4')) { // Riven uses this codec (as do some Myst ME videos) return Audio::makeADPCMStream(stream, true, stream->size(), Audio::kADPCMApple, _streams[_audioStreamIndex]->sample_rate, _streams[_audioStreamIndex]->channels, 34); diff --git a/engines/parallaction/sound_br.cpp b/engines/parallaction/sound_br.cpp index 761c5796b2..003861d501 100644 --- a/engines/parallaction/sound_br.cpp +++ b/engines/parallaction/sound_br.cpp @@ -422,7 +422,7 @@ Audio::AudioStream *DosSoundMan_br::loadChannelData(const char *filename, Channe flags |= Audio::Mixer::FLAG_LOOP; } - ch->stream = Audio::makeLinearInputStream((byte *)data, dataSize, rate, flags, loopStart, loopEnd); + ch->stream = Audio::makeRawMemoryStream((byte *)data, dataSize, rate, flags, loopStart, loopEnd); return ch->stream; } @@ -482,7 +482,7 @@ Audio::AudioStream *AmigaSoundMan_br::loadChannelData(const char *filename, Chan // TODO: Confirm sound rate int rate = 11025; - input = Audio::makeLinearInputStream((byte *)data, dataSize, rate, Audio::Mixer::FLAG_AUTOFREE, 0, 0); + input = Audio::makeRawMemoryStream((byte *)data, dataSize, rate, Audio::Mixer::FLAG_AUTOFREE, 0, 0); } else { input = Audio::make8SVXStream(*stream, looping); } diff --git a/engines/parallaction/sound_ns.cpp b/engines/parallaction/sound_ns.cpp index 7177ef60b9..7bd9970c64 100644 --- a/engines/parallaction/sound_ns.cpp +++ b/engines/parallaction/sound_ns.cpp @@ -376,7 +376,7 @@ Audio::AudioStream *AmigaSoundMan_ns::loadChannelData(const char *filename, Chan if (!scumm_stricmp("beep", filename)) { int rate = 11934; ch->volume = 160; - input = Audio::makeLinearInputStream((byte *)beepSoundBuffer, beepSoundBufferSize, rate, 0, 0, 0); + input = Audio::makeRawMemoryStream((byte *)beepSoundBuffer, beepSoundBufferSize, rate, 0, 0, 0); } else { Common::SeekableReadStream *stream = _vm->_disk->loadSound(filename); input = Audio::make8SVXStream(*stream, looping); diff --git a/engines/saga/music.cpp b/engines/saga/music.cpp index 37d211bc72..32f2a3d1a4 100644 --- a/engines/saga/music.cpp +++ b/engines/saga/music.cpp @@ -305,10 +305,10 @@ void Music::play(uint32 resourceId, MusicFlags flags) { if (!_digitalMusicContext->isCompressed()) { byte musicFlags = Audio::Mixer::FLAG_AUTOFREE | Audio::Mixer::FLAG_STEREO | Audio::Mixer::FLAG_16BITS | Audio::Mixer::FLAG_LITTLE_ENDIAN; - Audio::LinearDiskStreamAudioBlock audioBlocks[1]; + Audio::RawDiskStreamAudioBlock audioBlocks[1]; audioBlocks[0].pos = 0; audioBlocks[0].len = resData->size / 2; // 16-bit sound - audioStream = Audio::makeLinearDiskStream(musicStream, audioBlocks, 1, 11025, musicFlags, DisposeAfterUse::YES); + audioStream = Audio::makeRawDiskStream(musicStream, audioBlocks, 1, 11025, musicFlags, DisposeAfterUse::YES); } else { // Read compressed header to determine compression type musicFile->seek((uint32)resData->offset, SEEK_SET); diff --git a/engines/sci/sound/audio.cpp b/engines/sci/sound/audio.cpp index 54655eb0c7..5771debd60 100644 --- a/engines/sci/sound/audio.cpp +++ b/engines/sci/sound/audio.cpp @@ -244,7 +244,7 @@ Audio::RewindableAudioStream *AudioPlayer::getAudioStream(uint32 number, uint32 } if (data) - audioStream = Audio::makeLinearInputStream(data, size, _audioRate, flags | Audio::Mixer::FLAG_AUTOFREE); + audioStream = Audio::makeRawMemoryStream(data, size, _audioRate, flags | Audio::Mixer::FLAG_AUTOFREE); if (audioStream) { *sampleLen = (flags & Audio::Mixer::FLAG_16BITS ? size >> 1 : size) * 60 / _audioRate; diff --git a/engines/sci/sound/iterator/iterator.cpp b/engines/sci/sound/iterator/iterator.cpp index ab5f4db33f..513e74325c 100644 --- a/engines/sci/sound/iterator/iterator.cpp +++ b/engines/sci/sound/iterator/iterator.cpp @@ -551,7 +551,7 @@ static Audio::AudioStream *makeStream(byte *data, int size, int rate) { // Convert stream format flags int flags = Audio::Mixer::FLAG_AUTOFREE | Audio::Mixer::FLAG_UNSIGNED; - return Audio::makeLinearInputStream(sound, size, rate, flags, 0, 0); + return Audio::makeRawMemoryStream(sound, size, rate, flags, 0, 0); } Audio::AudioStream *Sci0SongIterator::getAudioStream() { diff --git a/engines/sci/sound/music.cpp b/engines/sci/sound/music.cpp index 59554b93a1..bea15ca900 100644 --- a/engines/sci/sound/music.cpp +++ b/engines/sci/sound/music.cpp @@ -177,7 +177,7 @@ void SciMusic::soundInitSnd(MusicEntry *pSnd) { if (track->digitalChannelNr != -1) { byte *channelData = track->channels[track->digitalChannelNr].data; delete pSnd->pStreamAud; - pSnd->pStreamAud = Audio::makeLinearInputStream(channelData, track->digitalSampleSize, track->digitalSampleRate, Audio::Mixer::FLAG_UNSIGNED); + pSnd->pStreamAud = Audio::makeRawMemoryStream(channelData, track->digitalSampleSize, track->digitalSampleRate, Audio::Mixer::FLAG_UNSIGNED); delete pSnd->pLoopStream; pSnd->pLoopStream = 0; pSnd->soundType = Audio::Mixer::kSFXSoundType; diff --git a/engines/scumm/he/cup_player_he.cpp b/engines/scumm/he/cup_player_he.cpp index a284632fb1..25baa24bde 100644 --- a/engines/scumm/he/cup_player_he.cpp +++ b/engines/scumm/he/cup_player_he.cpp @@ -175,7 +175,7 @@ void CUP_Player::updateSfx() { loopEnd = soundSize - 8; } _mixer->playInputStream(Audio::Mixer::kSFXSoundType, &sfxChannel->handle, - Audio::makeLinearInputStream(soundData + 8, soundSize - 8, 11025, flags, 0, loopEnd)); + Audio::makeRawMemoryStream(soundData + 8, soundSize - 8, 11025, flags, 0, loopEnd)); } } else { warning("Unable to find a free channel to play sound %d", sfx->num); diff --git a/engines/scumm/he/sound_he.cpp b/engines/scumm/he/sound_he.cpp index 8dd59ca388..bd003033c7 100644 --- a/engines/scumm/he/sound_he.cpp +++ b/engines/scumm/he/sound_he.cpp @@ -659,8 +659,8 @@ void SoundHE::playHESound(int soundID, int heOffset, int heChannel, int heFlags) flags |= Audio::Mixer::FLAG_AUTOFREE; - // makeADPCMStream returns a stream in native endianness, but LinearInputStream (and playRaw) - // is defaulted to Big Endian. If we're on a Little Endian system, set the LE flag. + // makeADPCMStream returns a stream in native endianness, but RawMemoryStream (and playRaw) + // defaults to big endian. If we're on a little endian system, set the LE flag. #ifdef SCUMM_LITTLE_ENDIAN flags |= Audio::Mixer::FLAG_LITTLE_ENDIAN; #endif diff --git a/engines/scumm/player_mod.cpp b/engines/scumm/player_mod.cpp index b148818d81..1b18b8f58f 100644 --- a/engines/scumm/player_mod.cpp +++ b/engines/scumm/player_mod.cpp @@ -94,7 +94,7 @@ void Player_MOD::startChannel(int id, void *data, int size, int rate, uint8 vol, _channels[i].pan = pan; _channels[i].freq = rate; _channels[i].ctr = 0; - _channels[i].input = Audio::makeLinearInputStream((const byte*)data, size, rate, Audio::Mixer::FLAG_AUTOFREE | (loopStart != loopEnd ? Audio::Mixer::FLAG_LOOP : 0), loopStart, loopEnd); + _channels[i].input = Audio::makeRawMemoryStream((const byte*)data, size, rate, Audio::Mixer::FLAG_AUTOFREE | (loopStart != loopEnd ? Audio::Mixer::FLAG_LOOP : 0), loopStart, loopEnd); // read the first sample _channels[i].input->readBuffer(&_channels[i].pos, 1); } diff --git a/engines/tucker/sequences.cpp b/engines/tucker/sequences.cpp index cd3423d8c2..d991a6e3de 100644 --- a/engines/tucker/sequences.cpp +++ b/engines/tucker/sequences.cpp @@ -598,7 +598,7 @@ Audio::RewindableAudioStream *AnimationSequencePlayer::loadSound(int index, Anim uint8 *sampleData = (uint8 *)malloc(size); if (sampleData) { f.read(sampleData, size); - stream = Audio::makeLinearInputStream(sampleData, size, rate, flags); + stream = Audio::makeRawMemoryStream(sampleData, size, rate, flags); } } break; |