No, [0, 1] is because you do a pondered mean between the last envelope value and the new value (see the code).Fluky wrote:Oops.
But, I'm converting the numbers using
exp( -1 / t * 1e-3 * samplerate), where t is the time value in seconds.
So is the [0,1] in seconds or what? Or I can use the above conversion so that dt is time in seconds?
The envelope produces some expansion since I'm applying it to a parameter that does not produce overgain in its value range. Still adding the envelope by multiplying the parameter with it leads to overflowing values, i.e. expansion, at some attack/release values. This must mean that the produced envelope does contain negative values (since the parameter I'm multiplying is all negatives, so it can't produce positive unless there's two negatives multiplied).
The envelope should never produce expansion, as it is a geometric mean/suit between former values.