1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Fix master channel check in MPEInstrument

This commit is contained in:
Tom Maisey 2019-03-19 11:18:39 +00:00 committed by ed
parent 096cad36a6
commit d5816ad186

View file

@ -607,7 +607,11 @@ bool MPEInstrument::isMasterChannel (int midiChannel) const noexcept
if (legacyMode.isEnabled)
return false;
return (midiChannel == 1 || midiChannel == 16);
const auto lowerZone = zoneLayout.getLowerZone();
const auto upperZone = zoneLayout.getUpperZone();
return (lowerZone.isActive() && midiChannel == lowerZone.getMasterChannel())
|| (upperZone.isActive() && midiChannel == upperZone.getMasterChannel());
}
bool MPEInstrument::isUsingChannel (int midiChannel) const noexcept