> The math behind it looks a bit complicated but for very long (envelope) phases you might need to update the current value manually because floating errors will add up
Sali Andre, I thought this would be a problem, but for exponential curves up to 5 seconds, ranging from 2^(1/12) start to 1 finish, I found my pow( end / start, curve / time / sampleRate ) method to never be off by a sample. For 10 seconds, sometims off by 1-3. (This all at 44.1kHz.) I calculate with doubles in C++, by the way. I had no idea it would be so accurate. For curves other than 0 and 1, I discover a delta that will work to the exact number of samples iteratively because I am too stupid to figure out an equation for delta. Werner is much better at math than I am! Please take a look at my soft synth if you're bored. I think there's nothing like it except Csound and Max/MSP/PureData, but I think my language is the easiest to read and write for more complicated patches. http://moselle-synth.com
_______________________________________________ dupswapdrop: music-dsp mailing list music-dsp@music.columbia.edu https://lists.columbia.edu/mailman/listinfo/music-dsp