Getting rid of clicks in amplitude curve based on random number

jbucks's icon

I am generating a curve based on a random number to modulate Gain (via the *~object) but I'm getting a lot of clicks. See the patch below:

Max Patch
Copy patch and select New From Clipboard in Max.

I tried to use a Slide object to smooth it out, but the more I smooth it, the more I lose the quick changes in the curve. I know WHY this is happening, I just don't know the best Max way of dealing with the problem. Am I approaching this problem in the right way? Thanks!

double_UG's icon

Max Patch
Copy patch and select New From Clipboard in Max.

jbucks's icon

Wow, thank you! I will go through that to understand the logic of how it works. Thanks again!