Sine Controller
Description
Outputs a sine-wave in each dimension.
(make-controller 'sine ... )
Lisp Syntax and Default Values
TheĀ 'sine controller can be created using the following Lisp syntax:
(make-controller 'sine dimension freq_controller phase)
Parameters
The 'sine controller takes two arguments:
- dimension: number of dimensions of the output controller.
- freq_controller: controller defining the frequency of the sine wave.
- phase: initial phase of the sine wave (in degrees).
The frequency controller determines frequency (or frequencies) of the output sine-wave(s). The dimension of this controller must equal the dimension of the sine-wave controller whose frequency it determines.
The initial phase parameter should be given, even if it is zero. Naturally, a cosine may be made by providing an initial phase of 90 degrees. Currently the phase parameter seems to only apply to the first dimension of the controller. This is a bug.
The sine controller is updated every synthesis sample period.
Discussion
A basic sine controller (at 440 Hz, for example) may be created like this:
(setq my-sine (make-controller 'sine 1 (const 440) 0))
(setq my-sine (make-controller 'sine 3 (const 1 2 5) 0))
Sine controllers can also be used to make synthesis, that can be used to resonate objects, as shown in Example 5.
Options
There are no special options for this controller.