From bb50d022f38b640512af9da15bd1d8cf1d73f53c Mon Sep 17 00:00:00 2001 From: Kevin <68612569+diyelectromusic@users.noreply.github.com> Date: Sat, 13 May 2023 11:27:51 +0100 Subject: [PATCH] Fix for Issue #471 Ignore MIDI All Notes Off in Omni mode (#493) Co-authored-by: probonopd --- src/mididevice.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/mididevice.cpp b/src/mididevice.cpp index 64fc009..e1f983c 100644 --- a/src/mididevice.cpp +++ b/src/mididevice.cpp @@ -324,7 +324,10 @@ void CMIDIDevice::MIDIMessageHandler (const u8 *pMessage, size_t nLength, unsign break; case MIDI_CC_ALL_NOTES_OFF: - if (!m_pConfig->GetIgnoreAllNotesOff ()) + // As per "MIDI 1.0 Detailed Specification" v4.2 + // From "ALL NOTES OFF" states: + // "Receivers should ignore an All Notes Off message while Omni is on (Modes 1 & 2)" + if (!m_pConfig->GetIgnoreAllNotesOff () && m_ChannelMap[nTG] != OmniMode) { m_pSynthesizer->notesOff (pMessage[2], nTG); }