mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-13 21:31:53 +00:00
SWORD25: Play the cutscene audio
Once the audio buffer has been queued in the audio stream, the Theora decoder is no longer responsible for it. It has to allocate a new audio buffer for the next set of audio data. Of course, at the moment the audio is pretty useless because the playback speed is all wrong. svn-id: r53939
This commit is contained in:
parent
09c678e363
commit
71e08336c0
@ -412,10 +412,11 @@ Graphics::Surface *TheoraDecoder::decodeNextFrame() {
|
||||
|
||||
// If playback has begun, top audio buffer off immediately.
|
||||
if (_stateFlag && _audiobufReady) {
|
||||
/* FIXME: This is currently crashing
|
||||
_audStream->queueBuffer((byte *)_audiobuf, AUDIOFD_FRAGSIZE, DisposeAfterUse::NO, Audio::FLAG_16BITS | Audio::FLAG_LITTLE_ENDIAN | Audio::FLAG_STEREO);
|
||||
*/
|
||||
|
||||
// The audio mixer is now responsible for the old audio buffer.
|
||||
// We need to create a new one.
|
||||
_audiobuf = (ogg_int16_t *)calloc(AUDIOFD_FRAGSIZE, sizeof(ogg_int16_t));
|
||||
_audiobufFill = 0;
|
||||
_audiobufReady = false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user