From adb2bbbb5902f0cb9f9c6ca6db81d57b723e1a23 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Sun, 10 Jul 2011 18:06:33 +0200 Subject: SCUMM: Properly implement volume controler for PC Speaker output. --- engines/scumm/imuse/pcspk.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'engines/scumm') diff --git a/engines/scumm/imuse/pcspk.cpp b/engines/scumm/imuse/pcspk.cpp index 6eaf7ad168..1b8afcabe5 100644 --- a/engines/scumm/imuse/pcspk.cpp +++ b/engines/scumm/imuse/pcspk.cpp @@ -307,8 +307,15 @@ void PcSpkDriver::MidiChannel_PcSpk::controlChange(byte control, byte value) { case 7: _tl = value; - // TODO: Properly implement this - _owner->updateNote(); + if (_owner->_activeChannel == this) { + if (_tl == 0) { + _owner->_lastActiveChannel = 0; + _owner->_lastActiveOut = 0; + _owner->_pcSpk.stop(); + } else { + _owner->output((_out.note << 7) + _pitchBend + _out.unk60 + _out.unkE); + } + } break; case 64: -- cgit v1.2.3