VST3 Velocity Clarification


I have noticed a couple of discrepancies regarding the implementation of note events velocity across hosts and plug-ins, which causes all sorts of approximation issues for customers. So it would be nice to have some clarifications about the possible values of the velocity:

  • is a noteOn event with 0 velocity equivalent to the MIDI protocol (this is a note off event)? Are such events valid in VST3, and should synth plug-ins consider this as a note Off event?
  • To be consistent with (1) f I were to convert MIDI to note events, is the right velocity equal to midiVelocity/127.0? (I have seen both /127.0 and /128.0 in the VST 3SDK?!?)
  • in the vst2wrapper, VST3 NoteOn events with velocity 0 are converted to MIDI Note Off events. Why? Shouldn’t they be equivalent?
  • as a VST3 Host, if I have a MIDI event that has velocity 0, should I pass it to the hosted VST3 synth as a VST3 NotOn event with 0 velocity or a Note Off event?
  • how should the velocity be used for NoteOff? What does a NoteOff event with velocity 0 means? Should it be ignored?


I cannot find the documentation myself at the moment, but in VST3 a Note-On is a Note-On event. Thus if a host receives a MIDI Note-On event with a velocity of zero, it must send a VST3 Note-Off event.
As a host, if you send a note-on event, you must send a note-off event with the same NoteID and to support the “Stop all notes” MIDI message, a host must know which note-ons were send to a plug-in, so than it can send a Note-Off event in this case.
And the formula to map from 7Bit MIDI-Velocity to 32bit VST3-Velocity should be midiVelocity/127.0. (Where is the 128 used in the SDK?)

I hope this answers all the questions, if not please let me know.


1 Like

Thanks this definitely answers the questions!

I have one more though: what does a NoteOn event with velocity 0 means in VST3 then?

I have found the following file with a quick search on “velocity” on GitHub (it could be a mistake from me as I haven’t read the entire code to check what it does, but it looks suspicious):

It means a silent note on.
For example if an instrument implements Note Expression (or in MIDI 2 nomenclature: Per Note Controller), you then start a voice in silence and with a note expression event you can raise the note volume afterwards.

Ah, the interapp audio stuff. It’s a typo I would guess, but that stuff is already deprecated.

Thanks for the clarification!