Forums > MaxMSP

modulting filtergraph~'s cutoff freq with function


nit
August 5, 2009 | 12:38 pm

i tried modulating filteraph~’s cutoff frequency with the function object but during the modulation i hear ticking artifacts in the sound. i tried using a line object between the function output and filtergraph’s cutoff freq input but i have to set it really high wich makes it response way to slow.
is there a better way?

here is an example of what i made for doing this:

– Pasted Max Patch, click to expand. –


jml
August 5, 2009 | 8:12 pm

Hi nit,

Here’s a solution that uses audio rate modulation of the frequency parameter by incorporating the filtercoeff~ object.
Note that I haven’t set up your constants.

– Pasted Max Patch, click to expand. –


nit
August 6, 2009 | 9:47 am

thanks, it seems this will work perfectly.


August 6, 2009 | 10:16 am

Hi,
i think the first problem in your patch, nit, is that you use a number~ instead of snapshot~ (i fell number~ can’t output value more often than 50 ms) Then snapshot~ should output one value at each vector.

Here the both ways using filtergraph or filtercoeff, will make different results when different vectors sizes are used. with big vector sizes of 1024 (for signal and I/O), it sounds better with filtergraph than filtercoeff, i shown the reason why in that topic : http://www.cycling74.com/forums/index.php?t=msg&th=40632

But hum, when i put vector sizes of 128 (for signal and I/O), it’s better with filtercoeff… Strange, normally it should be the same, as filtercoeff, in its default mode, only output signal values at each vector. (see the other topic)

There is some issue with max messages that not so precise after going thru filtergraff, i think… Even with "Scheduler in audio interrupt" ON. Then in the 3rd example using filtercoeff~->snapshot~, we don’t have this problem, it’s going exactly like filtercoeff when "Scheduler in audio interrupt" is ON.

Last thing, if you need the best precision(or want that the result doesn’t depend anymore about the vector size), the only way is to use the "resamp 1" message on filtercoeff, with very fast moves, you’ll notice the difference. (see the other topic)



nit
August 11, 2009 | 4:29 pm

Thank you very much for this explanation.

I’ve always overlooked the part of the snapshot~ help file with the ‘samples’ message to be honest. I never knew you even could specify its internal clock down to 1 sample.


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