[music-dsp] rms/peak level detection

Tom Erbe tre at shoko.calarts.edu
Mon Mar 13 17:04:39 EST 2000



John Robert wrote:
> 
> I am looking at gain processing algorithms. I haven't found much in the way of
> reference material on this, any pointers?

there are a couple info sites at different fx manufacturers - nothing
that gets too detailed - but enough to get you started.

http://www.proaudio.co.uk/drawmer/comp.htm

http://www.presonus.com/PreSonus__Tech_Education/presonus__tech_education.html

> In the level detection code, if one is doing peak detection, how many samples
> does one generally average over (if at all)? What kind of window size for RMS
> level detection? Is the RMS level detection generally the same algo. as peak,
> but with a bigger window?

that seems like something worth trying out.

> Finally, in a compressor, what is the difference between a compressor with a
> soft-knee and one with a slow attack/decay? They seem to do the same thing to
> me.

i'm not sure about the following - someone correct me if i'm off.
i think the attack and decay can be implemented by cross-fading the
compressed and uncompressed signal after the level crosses the
threshold. a soft-knee actually adjusts the compression ratio from 1:1
to the desired ratio about 10dB before the signal reaches the threshold.
so if the threshold is -30 dB and the ratio is 3:1, then the ratio ramps
up to 3:1 like this:

signal level      ratio
-50 dB            1:1
-40 dB            1:1
-35 dB            2:1
-30 dB            3:1
-20 dB            3:1

-- 
tom erbe | calarts | music | kcia | ceait
tre at shoko.calarts.edu

dupswapdrop -- the music-dsp mailing list and website: subscription info,
FAQ, source code archive, list archive, book reviews, dsp links
http://shoko.calarts.edu/musicdsp/




More information about the music-dsp mailing list