summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndré Nusser <andre.nusser@googlemail.com>2019-07-22 02:43:50 +0200
committerAndré Nusser <andre.nusser@googlemail.com>2019-07-22 02:43:50 +0200
commite2fb10f6dfb9fd92e34edc283bf61d50ab7fdc7a (patch)
tree9004c795d36b33cc4024fabd3f89801b5104b176
parent85f0c0b1adc57c33a7c4d3ef50ac22e7001739a1 (diff)
Small ammend to previous commit.
-rw-r--r--src/inputprocessor.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/inputprocessor.cc b/src/inputprocessor.cc
index 4b0b20f..fb783cf 100644
--- a/src/inputprocessor.cc
+++ b/src/inputprocessor.cc
@@ -194,8 +194,8 @@ bool InputProcessor::processOnset(event_t& event,
return false;
}
- auto const selected_level = (sample->getPower() - instr->getMinPower())/power_span;
- settings.velocity_modifier_current.store(selected_level / orig_level);
+ auto const selected_level = (sample->getPower() - power_min)/power_span;
+ settings.velocity_modifier_current.store(selected_level/event.velocity);
for(Channel& ch: kit.channels)
{