an open-source digital signal processing and sound synthesis language
about · links · contact
reset/control_rate - set the update rate for control functions and envelopes


Synopsis

reset(sampling_rate)
control_rate(sampling_rate)


Description

For instruments that are designed to use resetval in updating control functions and envelopes (pfields), reset determines how many times/second the control function/envelope is 'sampled'. For example,

   reset(44100)
will cause a control function to be sampled 44100 times/second (or once-every-sample for a standard 44.1k sampling-rate sound).

Why is this desired? Often it is not necessary to update control functions for every sample, and an instrument can run much more efficiently by choosing a lower sampling rate for control functions.

The default rate is 1000 times/second.

Most but not all RTcmix instrument control parameters will respond to the reset command. Exceptions for particular controls are usually noted in the instrument documentation.

If the reset rate is made too slow, a 'stair-stepping' or 'zippering' distortion effect can occur in control function access. especially noticeable in amplitude envelopes.

    NOTE: reset and control_rate do exactly the same thing. The perl RTcmix interface cannot use reset, for example, because the name is reserved in the language.


Arguments

sample_rate
Any number, floating point or integer represetig how many times/second the control/envelope (pfield) information will be updated during note execution.


Examples

   reset(10000)
   control_rate(22050)

See Also

rtsetparams