[sdiy] Fast envelope generation with variable slope

julian schmidt elfenjunge at gmx.net
Wed Dec 19 12:09:43 CET 2012


Regarding the recent fast envelope generation on 8 bit micro discussion, 
I'd be interested what would be the best/cheapest way to implement an 
envelope with variable slope exp/lin/log.

Some LUTs with interpolation come to mind.
Or an 1/x based shaper like the following

x = input in [-1..1]
y = output
k = 2*amount/(1-amount);

f(x) = (1+k)*x/(1+k*abs(x))

which is not exactly cheap containing the division and not exactly 
exp/log due to the 1/x shape.

The Idea from the fast envelope thread mentioned about the virus, 
modulating attack and decay values with the envelope output seems 
interesting as well! Got to try it someday.

generally for exp. envelopes I prefer the 1-pole approach.
But I don't know if it is possible in a similar way to generate log. 
curves or even get smooth transitions between the two.


More information about the Synth-diy mailing list