AuburnSounds / Dplug

Audio plugin framework. VST2/VST3/AU/AAX/LV2 for Linux/macOS/Windows.
https://dplug.org/
Other
479 stars 32 forks source link

Proper "touch" automation #813

Open p0nce opened 8 months ago

p0nce commented 8 months ago

"Touch" automation works for knobs and sliders but not press buttons. It makes erratic moves instead of cleanly reverting to automation start point.

I think this is because in a mouse gesture, the beginParamEdit/endParamEdit must match the click and unclick, which is not the case for every widget. Easy to see with Inner Pitch Full, automating press buttons there. Can repro in a DAW with so-called touch automation, such as Luna, Logic, Protools...

Interestingly, this is finally an explanation for why should beginParamEdit and endParamEdit need to exist.

p0nce commented 8 months ago

List of incorrect widgets:

Yeah. Almost all widgets are wrong but this doesn't break user sessions thankfully, it's just quite dangerous as a change.

p0nce commented 8 months ago

Studio One has "touch" automation, could be useful to repro.

So Studio One is more permissive than Luna with regards to this. Is this common across DAWs? We can expect Luna to handle this maybe.

(EDIT: exact same behaviour in REAPER than Studio One) (EDIT2: mostly same behaviour in Bitwig too, just Switch has different failure mode there)

=> Most host can fusion adjacent periods of beginParamEdit/endParamEdit to deal with what plugins do. Luna just doesn't do it yet. We only need to fix switch-like, radio buttons, push buttons, likely.

p0nce commented 8 months ago

Super-tricky a widget that call beginParamEdit in onMouseClick must deal with right-click coming while a drag is already there. This might produce