Smooth Parameter Automation

Hi @mrbombmusic

that’s actually not too complicated: I started with looking for a way to make fading of any paramater in a smooth way. Which means: make the fade somehow independant of the length of the live_loop it runs in. If I have a loop that runs for 8 beats I don’t want to wait that long until the parameter change and goes to the next value. So it was clear that I had to use control. My initial attempt goes like this (in the code above this is example 2):

  • Provide a ring of values and step through it using tick
  • use a control value and use tick again to advance within the ring
  • if e. g. I have a ring like (ring 0, 0.25, 0.5, 0.75, 1) the initial value for (let’s say) amp should be 0; then the control takes over and sets the amp to 0.25. And here comes, what’s wrong about this: Now, in the next loop run, the 3rd tick does not start at 0.25 but with 0.5 and goes to 0.75 with the next control.
  • so it was clear, I needed another ring for that (and I got input from Sam about that). The ring must look like: (ring 0, 0.25, 0.25, 0.5, 0.5, 0.75, 0.75, 1). That is, what the expression: (line 60, 100, steps: 10, inclusive: true).stretch(2).drop(1).butlast in example 1 is about. See the discussion in Manipualation of Rings to get further details about that.
  • now the 1st tick (to stay with the example of the amp value) takes the 0, the following control will take 0.25 with the 2nd tick, and then the 3rd tick will also have the 0.25 because the ring provides every value except the first one (.drop(1)) and the last one (.butlast) twice. (The .reflect in example 1 just let’s the filter value go back, when it has reached the maximum value.)

Hope this makes the background of my solution search more understandable

Now I would like 1. to have a function that provides me with a simple way to construct rings of that kind (which I sketched out here) and furthermore a way to be able to fade in/out a live_loop at any time, which is a bit more complicated because you will have to deal with the tick value to set it back. One way is to a) set the filter, amp or whatever value to the last reached position and then b) reset tick. After that you can use you ring again with the desired values (e. g. first you fade in the loop and then, after a while, you want to fade it out). So I know how, but I was wondering if it is somehow possible to cover that with one conveniant function …

Martin

1 Like