Difference between ar, kr, ir

I couldn’t find answers to what exactly are differences between different rates in sc. Can anyone explain this to me or provide useful sources to read?

Thanks!

ar means a full audio buffer of values are calculated for each control period.
kr means one value is calculated every control period, and then filled in with linearly interpolated values between the last value and the new value
ir is “initialized” and held for the duration of the ugen’s lifespan within its synthesis node instance. So - sampled at init time and held

Hope that helps
Josh

/*
Josh Parmenter
www.realizedsound.net/josh
*/

2 Likes

Hi and thanks for your answer. So what is a control period? And is it a variable I could also set in SC, or is it hard-coded and fixed?

Imagine that you have a hundred packets of paperwork to do today. They all have to go to the same offices in the same sequence.

So you take one packet and go physically to the first office, then the second office, then the third etc until that one is done. Then you do the same for the second packet… and the third…

Then you start thinking, that’s a lot of time just walking between offices. What if I took 20 or 30 packets at one time? Then, instead of walking to the same places a hundred times, I could do it with 3, 4 or 5 trips.

This is block processing of audio. Pretty much all audio software does it that way.

The operating system processes audio in blocks determined by the soundcard settings. SC wants more precise division of time, so it further subdivides the hardware buffer into its own control blocks or control periods. By default, a control block is 64 samples but you can change it before booting the server using the ServerOptions blockSize parameter. (You can’t change it while the server is running.)

hjh

1 Like