You can modulate parameters of oscillators, synths and fx. Various tutorials included with Gibber discuss modulation; “synthesis + fx” and “FM Synthesis” are two good ones to check out for more information on modulation.
The basic format of applying modulation is:
For example, basic tremolo looks like this:
s = Sine(); s.mod("mix", LFO(4, 1), "*");
In this case we modulate the amplitude of the sine wave by the output an LFO. We could also make a slightly more complicated where the amount of modulation fluctuates:
|1 2 3 4 5||
In this case, we’re using a second lfo to slowly vary the amount of modulation applied by our first LFO to the frequency of a sine wave.
There are three modes for modulation:
- “+” – add the output of the modulator to the modulated parameter
- “++” – add the absolute value of the modulator to the modulated parameter
- “*” – multiply the output of the modulator times the modulated parameter.
As seen with the frequency modulation example above, mods are applied recursively so that you can have as many layers of modulation as desired. The three types of modulators are:
- LFO – a low frequency oscillator… this is basically just a sine wave
- Step – a step sequencer that takes an array of values to pass and a time duration. NOTE: in the future this should change to use a regular Seq object
- Env – a attack/sustain/decay envelope. Env takes attack, decay, sustain and release in ms, but I think only attack, decay and sustain work right now…
- Line – a simple ramp with three parameters: duration, start value and end value