Route MIDI notes by velocity
Hello list,
I would like to route incoming MIDI notes by velocity. For exemple, with 4 zones (0-30,30-59,60-99,100-127), each notes coming with a velocity of 20 outs from the first output.
Could I achieve this with just one line in a "If" object?
Thanks
M
Yes If is limited to two outputs.
But maybe it's not the most pratical way, especially if you want, for example, to dynamically change the zones. I would use a combination of [split] and [gate] instead.
This is what I would do instead.
very clever !
Thank you TFL,
such use of if for list elements scare me. but you could introduce a $i3 to make it dynamic.
you usually need to split note events between vel 0 and vel non 0 anyway, just saying.
Ah, I would like also the note off (the "0") of the incoming notes goes out through the same output. In fact, it is a little patch to send notes to different midi channel according to their velocities.
A bit convoluted, but it works: using a coll to keep track of the channel of each note.
Maybe there is more simple approach, however!
that should not be a big deal, or ?
if midi input is a real one, then you can not produce same Note On
number without sending Note Off in between.
I use here multisplit jasch object, but you can also make abstraction
instead to dinamically change split ranges.
Note number gets ID prepended, depending on velocity split,
stored into coll, and next note Off of same pitch recalls it's ID ....
Simple, or ?
You can use ID to route to different channels or devices , whatever.

Great, thank you guys !
Yes, you can totally do that with just one line using the "If" object in your MIDI routing setup.