[sdiy] Fast envelope generation
tom at electricdruid.net
Tue Dec 18 21:38:26 CET 2012
On 18 Dec 2012, at 19:06, Donald Tillman wrote:
> And Tom, is your approach to the problem a lookup table for the curve?
Yes. Use a "phase accumulator"-style approach to move through a look-up table at variable speed, and use low bits from the accumulator to provide linear interpolation between table values.
This provides a simple way to stretch *any* curve to the required time, with no extra overhead for different curves and no calculation required beyond one multiplication for the interp. This is exactly what Gordon originally proposed, and exactly what I did in the code I posted.
I've tried other ways and I honestly don't see the point of a "more realistic" proper IIR RC simulation for this particular job. It doesn't add anything, it's far more limited (does one curve and one curve only), and it takes as much or more calculation.
But I'm willing to be convinced by good arguments!
More information about the Synth-diy