[sdiy] Lin/Log VCAs and envelopes - compensating for log VCAs
rburnett at richieburnett.co.uk
rburnett at richieburnett.co.uk
Fri Feb 12 18:20:00 CET 2016
Tom W wrote:
> The stored curve needs enough data to ensure this nosedive is
> at a low enough level to not be audible.
For an exponential function, you only really need to store one "octave's
worth" of the exp curve in a lookup table, (e.g. y=2^x for x=0 to x=1
where the output y goes smoothly from 0 to 1). You can then use the
method of range reduction to map this stored section of the curve for
x=0 to x=1 to all the other values of x outside this range, using binary
bit shifts to either double or halve the value.
You don't need to store many points in the lookup table for an expo
function. You can use linear interpolation between the LUT points, and
range reduction to cater for the regions outside the LUT bounds. That
piecewise linear expo approximation function I mentioned before, takes
this to the extreme and eliminates the LUT altogether, just doing linear
interpolation between 2^-2, 2^-1, 2^0, 2^1, 2^2, 2^3 etc.
-Richie,
On 2016-02-12 13:29, Tom Wiltshire wrote:
> This discussion has thrown up several important issues and problems
> with the way I was doing things in my PIC digital envelopes. These
> are:
>
> 1) Cropping the tail of the decay/release curve too harshly leads to
> an obvious "nose dive" in the output. This is visible here:
>
> http://www.tomwiltshire.co.uk/images/16LogADSROutput.png
>
> (Exponential ADSR plotted on a log scale, Sustain at 1/16th)
> Release is pretty much a straight line until -45dB, then nosedives to
> -100dB. The stored curve needs enough data to ensure this nosedive is
> at a low enough level to not be audible.
>
> 2) Using a linear decay into a log VCA doesn't give the same effect as
> an exponential decay into a linear VCA. This is visible at larger
> sustain settings:
>
> http://www.tomwiltshire.co.uk/images/2LogADSROutput.png
>
> (Exponential ADSR plotted on a log scale, Sustain at 1/2)
> Note that on the first graph with sustain at 1/16th, the decay does
> appear to be a straight line. This effect becomes more and more noted
> as the sustain gets smaller and smaller.
>
> 3) The usual "semi-linear" attack curve of ADSR generators that charge
> to x1.3 of the max value (this is all the CEM and SSM designs, as far
> as I can tell) doesn't seem to actually do a lot below -50dB. This is
> visible on either of the graphs above.
>
>
> I'm going to do some more work on this and I'll get back to you all
> when I've got some more data. Until then, I feel like I'm either just
> spouting opinions or speculating.
>
> Thanks for the discussion so far,
> Tom
>
>
>
> _______________________________________________
> Synth-diy mailing list
> Synth-diy at dropmix.xs4all.nl
> http://dropmix.xs4all.nl/mailman/listinfo/synth-diy
More information about the Synth-diy
mailing list