Smooth Preset Transition

May 18, 2009 at 4:04pm

Smooth Preset Transition

Is there away to make the transition between different presets smoother? i.e. a kind of “morphing effect” rather than a straight jump to the next set of values?

#43974
May 18, 2009 at 4:08pm

Hello
Your friends in this case are the pattr family. Take a look into the ‘Pattr Basics’ inside the max tutorials.
Emmanuel

#157948
May 18, 2009 at 4:55pm

Thanks, I will have to go back a re-read this tutorial.

The pattrstorage~ object looks likely for what I’m doing but it didn’t seem to be very obvious how you could incorporate a preset bank object that held a number of values.

#157949
May 18, 2009 at 5:10pm

The formula might be pattrstorage+autopattr+function
The best example you can find is the Andrew Benson’s recipe number 31:
http://www.cycling74.com/story/2006/2/17/153427/406

Emmanuel

#157950
May 18, 2009 at 6:12pm

Here check this out it should help. Key to making life easier is to use the autonamepattr with bpatchers so exclude objects that dont need controlling, patches far less messy.

Any questions let me know?

#157951
May 18, 2009 at 6:17pm

Ah, that really helps. Thanks for that.

#157952
May 18, 2009 at 6:17pm
pmj wrote on Mon, 18 May 2009 11:55
The pattrstorage~ object looks likely for what I’m doing but it didn’t seem to be very obvious how you could incorporate a preset bank object that held a number of values.

Set up your pattrstorage with the pattrs you want, then make a regular preset object. In the Inspector, type the name of your pattrstorage, and it’ll be linked to it. No need to connect the preset to anything in this case. It won’t let you choose a non-existent pattrstorage name in the Inspector.

Now when you use the preset as usual, shift-click to store is the same as “store $1″ message to pattrstorage, and click to recall is the same as sending pattrstorage an integer. This method (using integers or clicking the preset) won’t interpolate, you need to use a float # to pattrstorage to get at the in-between values. Or you can do a recall between two non-adjacent stored slots by
recall $1 $2 $3
where $1 is the first, $2 is the second stored slot, and $3 is a number between 0. and 1. which tells “where” to go between the two values.

pattr is quite amazing…

#157953
May 18, 2009 at 6:18pm

Its really useful little bit of code, so use it well my friend.

#157954
May 18, 2009 at 6:19pm

seejay great tip, this is why I love MAX there is always more to learn.

#157955
May 18, 2009 at 7:09pm
MadBeat wrote on Mon, 18 May 2009 12:18
Its really useful little bit of code, so use it well my friend.

…the only thing I’ve just noticed is that it doesn’t go from one preset to the next smoothly. I’ve added a line~ and [1,2 1000] ramp command as in the help file for pattrstorage~ but no dice. Any idea what I may be doing wrong?

#157956
May 18, 2009 at 7:44pm

line~ wouldn´t work, because its for audio.

and in “line” you need to specify expressly that its sending out float values
(look in the helpfile: line for floats)

hth
hans

#157957
May 18, 2009 at 10:15pm

Great, thanks for all the tips guys. Very helpful.

#157958
May 19, 2009 at 12:00am

I use the pattr preset approach in the third part of my 12th tutorial:

http://www.youtube.com/watch?v=-G1jnVyXc8k

Baz

#157959
May 19, 2009 at 2:12am

Look at the “recallmulti” message to [pattrstorage] if you have’t noticed it already. You can intepolate between multiple non-adjacent slots, in a word: awesome!

lh

#157960
May 19, 2009 at 10:01am

hi,

i made something to manage preset with interpolation.it’s not perfect but maybe it will help…
http://pan-etc.net/res/dev/Preset-v5.zip

#157961
May 19, 2009 at 10:17am

Thanks again guys, great stuff – all useful.

#157962
May 19, 2009 at 2:27pm

you might also like to look at int.lib for controlling smooth preset transitions graphically…

http://www.olilarkin.co.uk/index.php?p=max

max5 version coming sometime soon i hope

#157963

You must be logged in to reply to this topic.