Forums > MaxMSP

how to combine line~ with messages to gradually change vst~ parameters

October 5, 2008 | 6:29 pm

Hi there,

Im trying to make a patch around the fab filter 1 computer music edition, that smoothly changes some of its parameters.

Until now I have only been sending messages with the parameter number and 0-1 value. I do not know (yet) how to combine (line~) information with the messages to overcome the static nature of messages.

Im I on the right track here ? (line~)

Cheers & thanks



MIB
October 5, 2008 | 8:45 pm

have a look at the helpfile for line.
line~ is for signals and since you want to change parameters you probably should be looking at line.


October 5, 2008 | 9:19 pm

for floats or integers use line. you could also look into pattr for your values: this allows "keyframing" of values and interpolation between them. line only goes from one to another smoothly, which is great for most things, but pattr can move nonlinearly. Maybe get line working first, then look into pattr (which is great for a whole bunch of other things too…)

if you’re at 0.25 and you want to go to 0.75 in 2.5 seconds, send the message 0.75 2500 to line (2500=milliseconds). The second argument in the actual line object is the time grain (update interval). I usually use 30-50 ms in there, that’s quite smooth. If it’s at 250, say, you’ll get a number out every quarter second.


October 6, 2008 | 8:44 am

Quote: seejayjames wrote on Sun, 05 October 2008 15:19

> if you’re at 0.25 and you want to go to 0.75 in 2.5 seconds, send the message 0.75 2500 to line (2500=milliseconds). The second argument in the actual line object is the time grain (update interval). I usually use 30-50 ms in there, that’s quite smooth. If it’s at 250, say, you’ll get a number out every quarter second.
>
—————————————————-

Thanks, but how to specify parameter number then?



MIB
October 6, 2008 | 4:46 pm

maybe something like this?

– Pasted Max Patch, click to expand. –

October 6, 2008 | 5:27 pm

Thank you,

It looks very promising, but I dont get it to work, I connect the output of the message last in the chain to the vst~ fabfilter one, use number 6 (filter freq) as the first argument after "pak param" but the filter freq parameter doesnt seem to move.


October 6, 2008 | 6:04 pm

Hi

"params" message outputs parameter names (from 4th-from-rightmost
outlet) and does *not* set parameters values.

from [vst~] reference:
"list: In left inlet: Changes a parameter value in the currently loaded
plug-in. The first list element is the parameter number (starting at 1)
and the second element is the parameter value. The second number should
be a float between 0 and 1, where 0 is the minimum value of the
parameter and 1 is the maximum."

So, for parameter 6 (and a ramp time of 100ms):

flonum
|
pack f 100
|
line 0.
|
prepend 6
|
vst~

BTW, I advice you to go through the tutorials, this should be covered in
the first ones, and they are really worth it ;)

Ciao



MIB
October 6, 2008 | 6:08 pm

if you just used my patch it won’t work since I connected the pak to the right inlet of the message box (it will only disply, but not output the message!!!). try connecting directly from pak or go through the left inlet of a message box…



MIB
October 6, 2008 | 6:12 pm

…also make sure the param message is the one to change your parameter and not asks for them to be output. I am not using VSTs much so I don’t know what you would need. I just used param because that’s what you had in your post!!!


October 7, 2008 | 8:34 am

aha – Prepend !

Thanks all !


Viewing 10 posts - 1 through 10 (of 10 total)