Parameter smoothing in gen~

    Jul 13 2013 | 12:02 pm
    Hi guys, trying to do parameter smoothing in gen~. Any strategy? I've tried this following simple thingie but doesn't provide the required amount of smoothing. Have to use audio rate parameters outside of gen~ (i.e. using sig~ )
    thanks a.

    • Jul 13 2013 | 12:23 pm
      Hi Alfonso
      Gregory Taylor's response to my recent "line~ as counter" question here might help. Very nice interpolation idea.
    • Jul 13 2013 | 1:43 pm
      In itself the strategy works well, it's just that the argument for mix should be much closer to 1. This setup behaves similar to slide~.
    • Jul 13 2013 | 1:55 pm
      many thanks guys! useful infos!
    • Dec 18 2013 | 6:49 pm
      I just made this gen~ patch inspired by supercollider's "lag3". Very useful for parameter smoothing. Unlike line~ it has a smooth start and end, in some cases producing less unwanted artifacts.
    • Dec 19 2013 | 8:38 am
      Great - thanks!
    • Apr 27 2014 | 10:02 pm
      I made this, it's simple. For faster response the .01 could be higher (and .99 changed the two coefficients still add up to 1). I think it could be twice or more faster, but I didn't need it.
      One nice thing is, with faster audio rates, the difference between samples is smaller, so the coefficients don't need to change when sample rate changes.
    • Apr 27 2014 | 10:47 pm
      i use the basic idea of a moving-average filter: 0.5(n + n-1) but alter it for differing needs.... (uh... in case it needs be said: n = current sample, n-1 = previous...)
      I really dig Tarik's though :D
    • Feb 18 2015 | 3:39 pm
      Im trying to do exactly this but I can't find the 'history' object! What does it do and where can I get it?
    • Feb 18 2015 | 7:44 pm
      use gen?
    • Feb 18 2015 | 11:08 pm
      The mix/history combo is the same as a one pole (and Ernest's example is also a one pole).
      Tarik's is three one poles in series, with some code for calculating the desired coefficient from a duration (and constant target threshold). BTW, in Tarik's code the abs() is unnecessary, so the onepole() is still equivalent to mix+history. Here's the same, slightly re-arranged:
    • Feb 19 2015 | 12:45 am
      ooh. Pretty!