Dynamics Comp Makeup values
-
@SteveRiggs Technically speaking, keeping the level even would just be another compressor. All of the makeup gain math I've seen is a formula of the threshold and ratio settings. If your input signal is really low, you'll have to crank down the threshold to start compressing, but doing so will increase the makup gain level. You can tinker with the formula to find something that works for your situation.
And just to be sure, once you changed this line, you recompiled HISE and used the new version, right?
Changing the code alone in Dynamics.cpp will not work. -
@dustbro said in Dynamics Comp Makeup values:
And just to be sure, once you changed this line, you recompiled HISE and used the new version, right?
Ahhh, that I didn't do My bad! I will try it. Thanks.
@dustbro said in Dynamics Comp Makeup values:
keeping the level even would just be another compressor
I was thinking if maybe that was an easier option. Hopefully, it wouldn't add any noticeable latency if running a few dynamics modules. I'll experiment with a few things. Thanks man
-
Did a little more tinkering
if (compressorMakeup) { if (compressor.getThresh() >= 0.1f) { auto attenuation = compressor.getThresh(); auto ratio = compressor.getRatio(); auto gainDb = log2f(-attenuation / ratio); compressorMakeupGain = (float)Decibels::decibelsToGain(gainDb); } else { compressorMakeupGain = 1.0f; } } else compressorMakeupGain = 1.0f;
-
@dustbro Cool! Hows it sounding?
-
@SteveRiggs My favorite so far. Nice and even output.
-
@dustbro Skills mate! I'll recompile and try it this eve.
I had a go at doing it for the limiter as well but the code is laid out slightly differently for the limiter section so I'm not sure how it would work for that part. Any ideas?
-
@dustbro Sir, Could You Please Upload The Dynamics.cpp File! So We Can Swap Them!!!
Because I'm All New To This And Don't Want To Mess Up The Codes
Thanks -
@Natanr
Here you go
I haven't compiled it and tested it yet so make a copy of the original Dynamics.cpp file and put it to one side before you change it in the source code, just in case.
-
@SteveRiggs I'm gonna look at the limiter code next
-
@dustbro Awesome :)
-
@SteveRiggs Thanks Steve, I Really Appreciate You Man
-
@Natanr No worries mate :clinking_beer_mugs:
-
and my final resting place:
if (compressorMakeup) { auto attenuation = compressor.getThresh(); auto ratio = compressor.getRatio(); auto gainDb = (1.0 - ratio) * (attenuation * -1.0) * 0.7; compressorMakeupGain = (float)Decibels::decibelsToGain(gainDb); } else compressorMakeupGain = 1.0f;
-
@dustbro Nice! Even smoother now?
-
@SteveRiggs for now.....
-
@dustbro
-
-
@SteveRiggs the limiter makeup gain is set exactly to the inverse of the threshold control.
(limiter.getThresh() * -1.0);
You could divide into that equation to dull down the limiter makeup gain.
maybe something like:((limiter.getThresh() * -1.0) * 0.2);
That would give you 20% of the existing value as makeup gain.
-
@dustbro Awesome! Thanks man, I'll try this out.
...and perfect timing as well. Just about to recompile the new version :) Legend mate. Cheers!
-
@SteveRiggs @dustbro @SteveRiggs Bro Could You Please Supply The .cpp For Limiter And Compressor File So I Can Swap Them With Confidence God Bless