From 7a1d359342579d0d48c59d120ec734d215cd73c8 Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Sat, 16 Sep 2017 17:57:37 -0400 Subject: TITANIC: Fix music playback in music room --- engines/titanic/sound/music_room_handler.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'engines/titanic') diff --git a/engines/titanic/sound/music_room_handler.cpp b/engines/titanic/sound/music_room_handler.cpp index ffc90ffca6..5c1cd6012d 100644 --- a/engines/titanic/sound/music_room_handler.cpp +++ b/engines/titanic/sound/music_room_handler.cpp @@ -218,9 +218,9 @@ void CMusicRoomHandler::updateAudio() { // Iterate through each of the four instruments and do an additive // read that will merge their data onto the output buffer for (count = size, ptr = audioData; count > 0; ) { - int amount = musicWave->read(ptr, count); + int amount = musicWave->read(ptr, count * 2); if (amount > 0) { - count -= amount; + count -= amount / sizeof(uint16); ptr += amount / sizeof(uint16); } else if (!pollInstrument(instrument)) { --_instrumentsActive; -- cgit v1.2.3