Hi there team!
I've recently noticed a weird thing whereby a CLAP plugin (specifically with MIDI-out functionality enabled) will lose note velocity bit by bit. As far as I can tell, this appears to be related to an integer/floating-point roundtrip conversion issue. There are certain velocity values that remain stable, but notes with velocities below 9 in particular lose one point for every instance of such a plugin in the chain, disappearing completely when the velocity reaches 0, as you would perhaps expect.
VST3 builds of essentially the same plugins aren't affected, nor are CLAP plugins that pass MIDI straight through unaltered.
Specifically, if I multiply the velocity by 128.0/127.0 proactively then the problem goes away, but I've been assured by my audio plugin framework's lead developer that this shouldn't be necessary and is a problem with Reaper's handling of CLAP's velocity somewhere along the line. After further digging, this is somewhat borne out by the fact that (e.g.) fellow CLAP host MuLab doesn't do any of this.
If it's helpful for testing, here's a
CLAP plugin that should simply echo the incoming MIDI.
Thoughts would be most appreciated