brummer10 / guitarix

guitarix virtual versatile amplification for Jack/Linux
249 stars 26 forks source link

Hard Limiter ratio and threshold #45

Closed Rippert closed 3 years ago

Rippert commented 3 years ago

I was testing out the latest commit with the Limiter meter, and I noticed it started limiting long before the main output meter goes into the red. Looking at the code, you've got a ratio of 4 and a threshold of -6dB. These are pretty low for what I would consider a hard limiter. More like an output compressor.

When I set up an output limiter on my mixer, I set the ratio to 100, and the threshold to 0dB. I also set a slightly soft knee, which seems similar to what you are doing in your code. That way the compressor kicks in a little below 0dB but really limits the signal quickly as it tries to go above 0dB.

I tried this in hardlim.dsp, and it seemed to work well for me. Only coming on when the main output meter was well into the red, and not allowing any digital clipping that I could hear.

Maybe I don't understand your reason for using the softer compression, but it may be worth trying this out for yourself and see if it does what you want. It is less intrusive on the overall sound of the amp, but does provide a hard limit.

I realize that I can just turn down the Master Volume knob and turn up my Hardware Power Amp gain, which I was doing. So maybe this doesn't need to be changed if you've got reasons for the softer compression limiter.

brummer10 commented 3 years ago

Yes, my intentional idea was to keep a bit more headroom, but it's true, that needs to be decided by anyone itself. So I follow your suggestion and put the threshold to 0dB. Thanks as always hermann

Rippert commented 3 years ago

Built the new commit. Seems to work well. Thanks.