LFO pitch connections
LFO pitch connections are a feature exclusive to SynthEnginePro, which enables you to create a wide variety of effects by modulating oscillator pitch (or frequency) as notes play. Connections can be made to specific oscillators or to all oscillators added to a synth.
gml
synth = synth_create();
synth_add_osc(synth, synth_waveform_sine);
synth_add_osc(synth, synth_waveform_square);
var _saw_osc = synth_add_osc(synth, synth_waveform_saw);
var _amount = 1; // +/- 12 semitones
LFO = synth_add_lfo(synth, synth_waveform_sine, 10, _amount);
// Modulate the pitch of all oscillators attached to this synth
synth_connect_lfo_pitch(synth, LFO);
// Modulate the pitch of only the saw wave oscillator
synth_connect_lfo_pitch(synth, LFO, _saw_osc);
LFO pitch amount
The amount
parameter of the LFO dictates how far above and below to modulate the original frequency of a note. A value of 1 is equal to a full octave, so you can calculate specific semitone offsets by dividing by 12 (since there are 12 semitones in an octave):
gml
var _amount = 1 / 12; // +/- 1 semitone
var _amount = 7 / 12; // +/- 7 semitones
var _amount = 24 / 12; // +/- 2 octaves
LFO = synth_add_lfo(synth, synth_waveform_sine, 10, _amount);
When the LFO wave is above the midline it modulates pitch positively, and when below the midline it modulates the pitch negatively.