make note on/off MIDI control do something sensible, rather than attempt to use the...
authorPaul Davis <paul@linuxaudiosystems.com>
Fri, 20 Jul 2012 15:10:10 +0000 (15:10 +0000)
committerPaul Davis <paul@linuxaudiosystems.com>
Fri, 20 Jul 2012 15:10:10 +0000 (15:10 +0000)
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@13057 d708f5d6-7413-0410-9779-e7cbd77b26cf

libs/surfaces/generic_midi/midicontrollable.cc

index 18c582f8b0de5bc215f5f68f71ecd12df0bac2a6..7c91dd559aae2e5353190cfd4a763220e21955aa 100644 (file)
@@ -128,7 +128,9 @@ void
 MIDIControllable::midi_sense_note (Parser &p, EventTwoBytes *msg, bool is_on)
 {
        if (!bistate) {
-               controllable.set_value (msg->note_number/127.0);
+               if (msg->note_number == control_additional) {
+                       controllable.set_value (msg->velocity/127.0);
+               }
        } else {
 
                /* Note: parser handles the use of zero velocity to