diff options
Diffstat (limited to 'src/chips/opal/opal.hpp')
-rw-r--r-- | src/chips/opal/opal.hpp | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/chips/opal/opal.hpp b/src/chips/opal/opal.hpp index f554920..c383bd5 100644 --- a/src/chips/opal/opal.hpp +++ b/src/chips/opal/opal.hpp @@ -1237,12 +1237,9 @@ void Opal::Operator::SetFrequencyMultiplier(uint16_t scale) { //================================================================================================== void Opal::Operator::SetKeyScale(uint16_t scale) { - if (scale > 0) - KeyScaleShift = 3 - scale; - - // No scaling, ensure it has no effect - else - KeyScaleShift = 15; + /* libADLMIDI: KSL computation fix */ + const unsigned KeyScaleShiftTable[4] = {8, 1, 2, 0}; + KeyScaleShift = KeyScaleShiftTable[scale]; ComputeKeyScaleLevel(); } |