lucianodato / noise-repellent

Lv2 suite of plugins for broadband noise reduction
GNU Lesser General Public License v3.0
455 stars 38 forks source link

Bypass button not working in Ardour #113

Open davidhealey opened 2 years ago

davidhealey commented 2 years ago

As the title. Pressing the bypass button or the enable button doesn't appear to do anything.

lucianodato commented 2 years ago

Ok will check asap

davidhealey commented 1 year ago

Any progress on this?

nettings commented 1 year ago

I can confirm this behaviour. Ardour's bypass button seems to control the "enable" switch in the plugin, which in turn doesn't do anything. I think (but I'm not sure) Ardour patches around a plugin to "bypass" it only if it doesn't see the plugin has such a feature, and tries to use the plugin's bypass feature if it does. So I would suspect that the issue is not limited to Ardour.

A quick look at signal_crossfade_run tells me there seems to be a low-pass filtered dynamic wet/dry coefficient, but I don't quite understand the logic. The target is updated once per buffer, but shouldn't the dynamic coefficient be updated once every sample? So I guess the line

self->wet_dry += self->tau * (self->wet_dry_target - self->wet_dry);

should go into the loop in signal_crossfade_run()...? Or am I being confused about how this is supposed to work?

thomask-gh commented 1 year ago

The issue is still there with Ardour 7.2.0 and Noise Repellent v0.2.3. I’m new to DAWs and I was first learning how Noise Repellent works and got very confused to hear no difference between having the plugin enabled or not, even when giving it extreme settings on purpose, only to find out there was a difference when I removed the plugin from my bus altogether. It made me suspect that the enable/bypass feature might be broken, and it indeed is.

It would be great if you could fix this, but thanks a lot for this plugin anyway!

jmaibaum commented 2 months ago

Just noticed this as well using Ardour 8.6 + NR 0.2.3. This is really confusing.

davidhealey commented 2 months ago

Just noticed this as well using Ardour 8.6 + NR 0.2.3. This is really confusing.

I don't think it's likely we will get a fix for this any time soon. But I would recommend you use v0.1.5 as all versions from 2.0.0 have bugs and glitches and I've found 0.1.5 gives the best results.

jmaibaum commented 2 months ago

Yes, I also switched to 0.1.5 after I noticed that 0.2.0 also had this bug.

davidhealey commented 2 months ago

Yes, I also switched to 0.1.5 after I noticed that 0.2.0 also had this bug.

Here's another tip, set the release to at least 500 to avoid the bird chirping sound

jmaibaum commented 2 months ago

The reason why bypass is not working is because input and output can be at the same memory location according to the LV2 spec:

Plugin writers should be aware that the host may elect to use the same buffer for more than one port and even use the same buffer for both input and output (see lv2:inPlaceBroken in lv2.ttl).

(Quote from: https://lv2plug.in/c/html/group__lv2core.html#a4d904937a1bd27cb5f5478f95c708b16)

The author of #118 mention this, and my tests were also showing input and output pointing to the same address, making the crossfade code a no-op.

Unfortunately though not all LV2 hosts seem to support lv2:inPlaceBroken which would be a spec compliant solution for noise-repellent...