nih-plug icon indicating copy to clipboard operation
nih-plug copied to clipboard

Spectral Compressor: FFT latency in VST3 is right, in CLAP it's broken

Open Vospi opened this issue 10 months ago • 1 comments

Hey there. Latest legit FL Studio 2024 here, on Windows.

https://github.com/user-attachments/assets/fb9a519b-36ff-4726-9716-fdf2b3b6091c

Video attached with the demonstration. The CLAP version does not report a change in latency to the host, but VST3 does. Thus, you can only use VST3, or never switch away from 2048.

Vospi avatar Feb 07 '25 12:02 Vospi

More info on this: when the latency changes while the plugin is currently activated it should call host_callback=>request_restart, which nih-plug does correctly(ish) here: https://github.com/robbert-vdh/nih-plug/blob/28b149ec4d62757d0b448809148a0c3ca6e09a95/src/wrapper/clap/wrapper.rs#L392-L407

However it should should then call host_latency=>changed while being re-activated, which doesn't happen as far as I can tell: https://github.com/robbert-vdh/nih-plug/blob/28b149ec4d62757d0b448809148a0c3ca6e09a95/src/wrapper/clap/wrapper.rs#L1870-L1911

@robbert-vdh does this seem correct and actionable?

edwloef avatar Sep 16 '25 19:09 edwloef