Change MIDI velocity implementation to allow direct control of velocity value (#9940)

* Initial changes to expose "real" MIDI velocity

* Change MI_VELU and MI_VELD to fit new logic

* Apply cleanups from fauxpark's review

my bad on the errant whitespace and else {} placements

* Slight changes to MI_VELD to match values when velocity is falling to when it is rising

* Add keycode MI_VEL_0

* Update compute_velocity() to handle MI_VEL_0

* Store velocity as 7 bits to hard cap value at 127
This commit is contained in:
jakobkg 2020-09-20 03:13:45 +02:00 committed by James Young
parent 73d20754bb
commit bf84d35117
No known key found for this signature in database
GPG key ID: 8E1085BF6FCFBD74
3 changed files with 21 additions and 9 deletions

View file

@ -343,7 +343,8 @@ enum quantum_keycodes {
MI_TRNSU, // transpose up
MIDI_VELOCITY_MIN,
MI_VEL_1 = MIDI_VELOCITY_MIN,
MI_VEL_0 = MIDI_VELOCITY_MIN,
MI_VEL_1,
MI_VEL_2,
MI_VEL_3,
MI_VEL_4,