From ace610fe613d6eb7633aec98632966d09540dd46 Mon Sep 17 00:00:00 2001 From: Wohlstand Date: Wed, 16 Sep 2020 21:17:34 +0300 Subject: Added old and buggy HMI volume model It's needed to make a correct sounding of music of some game soundtracks such as "Asterix & Obelix" TODO: Verify the behavior of drums, seems still being different! --- src/adlmidi_midiplay.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/adlmidi_midiplay.cpp') diff --git a/src/adlmidi_midiplay.cpp b/src/adlmidi_midiplay.cpp index c6fc1b6..8d92933 100644 --- a/src/adlmidi_midiplay.cpp +++ b/src/adlmidi_midiplay.cpp @@ -1247,7 +1247,7 @@ void MIDIplay::noteUpdate(size_t midCh, { const MIDIchannel &ch = m_midiChannels[midCh]; bool is_percussion = (midCh == 9) || ch.is_xg_percussion; - uint_fast32_t brightness = is_percussion ? 127 : ch.brightness; + uint_fast32_t brightness = ch.brightness; if(!m_setup.fullRangeBrightnessCC74) { @@ -1262,7 +1262,8 @@ void MIDIplay::noteUpdate(size_t midCh, vol, ch.volume, ch.expression, - static_cast(brightness)); + brightness, + is_percussion); /* DEBUG ONLY!!! static uint32_t max = 0; -- cgit v1.2.3