dynamic ramp curve

Aug 9, 2012 at 7:49am

dynamic ramp curve

Hi all,

I’d like to have a dynamic curve that scales my input as follows:
when the input number is increasing the ramp is steeper, so for instance an input of 4 becomes a 7
when the input number is decreasing the ramp is more lazy, so that a 4 becomes a 2 (these numbers just to give an idea)

I actually managed to do that very simply, by changing the exponential argument of a scale object, as the attached patch shows – of course i need to add [change +] and [change -].

The real problem comes when the argument changes, because while i only want the last output number to change its deceleration curve, as a matter of fact what i have i a sudden jump to another number. And this is completely unwanted.
Do you have any tip?
Thanks!

– Pasted Max Patch, click to expand. –
#63915
Aug 9, 2012 at 11:53pm

probably the most inelegant solution ever, i came out with this.
Sometimes values jumps as well, so apart from aesthetic, it may be improved on the functional part, as well.
Any ideas on how to improve it?
thanks!

– Pasted Max Patch, click to expand. –
#230487
Aug 28, 2012 at 3:54pm

mmm.. still no one? ;-)

#230488
Aug 28, 2012 at 4:39pm

I think the slide object is what you want. You’ll need to play with it a bit to figure out the desired slide-up and slide-down values.

#230489
Aug 28, 2012 at 7:10pm

The formula for slide is a little tricky in that it won’t get to the exact value at the specified time, since it’s never going to actually reach the target value (it just approaches it asymptotically, though with round-off error you’ll probably eventually get there, but the timing is probably important). I’ve attached an example that improves the timing precision of slide. You can also use curve~ at signal rate.

– Pasted Max Patch, click to expand. –
#230490

You must be logged in to reply to this topic.