Voice Manipulation functions. More...
Functions | |
function | changePan (voiceId, pan, relative, immediate) |
changes the pan position of a specific note event. More... | |
function | changeTune (voiceId, shift, relative, immediate) |
change the tuning of specific voice in (fractionnal) semitones. More... | |
function | changeVolume (voiceId, gain, relative, immediate) |
changes a voice's volume. More... | |
function | changeVolumedB (voiceId, dBGain, relative, immediate) |
change the volume of specific voice in decibels. More... | |
function | fade (voiceId, targetValue, duration, layer) |
starts a volume fade. More... | |
function | fade2 (voiceId, startValue, targetValue, duration, layer) |
starts a volume fade. More... | |
function | fadein (voiceId, duration, reset, layer) |
starts a volume fade-in for a specific voice. More... | |
function | fadeout (voiceId, duration, killVoice, reset, layer) |
starts a volume fade-out. More... | |
function | sendScriptModulation (id, targetValue, rampTime, voiceId) |
send a script modulation event to control a Script Modulation source. More... | |
function | sendScriptModulation2 (id, startValue, targetValue, rampTime, voiceId) |
send a script modulation event to control a Script Modulation source. More... | |
function | setSampleOffset (voiceId, value) |
changes a sample starting point in milliseconds. More... | |
Voice Manipulation functions.
function sendScriptModulation | ( | id | , |
targetValue | , | ||
rampTime | , | ||
voiceId | |||
) |
send a script modulation event to control a Script Modulation source.
enables per voice script-driven piece-wise linear modulation source control.
id | the modulation source id (can be changed on each modulation source) |
targetValue | the modulation value in [0;1] if the source is unipolar or [-1;1] if the source is bipolar |
rampTime | the rampTime in milliseconds (defaults to 20ms) |
voiceId | the optional voice id of the voice to be controlled. If it is not specified then the value is the same for all voices (broadcast mode). |
function sendScriptModulation2 | ( | id | , |
startValue | , | ||
targetValue | , | ||
rampTime | , | ||
voiceId | |||
) |
send a script modulation event to control a Script Modulation source.
enables per voice script-driven piece-wise linear modulation source control.
id | the modulation source id (can be changed on each modulation source) |
startValue | the start modulation value in [0;1] if the source is unipolar or [-1;1] if the source is bipolar |
targetValue | the target modulation value in [0;1] if the source is unipolar or [-1;1] if the source is bipolar |
rampTime | the rampTime in milliseconds (defaults to 20ms) |
voiceId | the optional voice id of the voice to be controlled. If it is not specified then the value is the same for all voices (broadcast mode). |
function changeTune | ( | voiceId | , |
shift | , | ||
relative | , | ||
immediate | |||
) |
change the tuning of specific voice in (fractionnal) semitones.
voiceId | id of the voice to be transposed |
shift | transposition in semitones to be applied |
relative | (optional) specify if the transposition is relative to the last changeTune transposition, default to false |
immediate | (optional) apply transpostion without smoothing, default to false |
Example:
function changePan | ( | voiceId | , |
pan | , | ||
relative | , | ||
immediate | |||
) |
changes the pan position of a specific note event.
voiceId | id of the voice to be transposed |
pan | panoramic position between -1 and 1 |
relative | (optional) specify if the transposition is relative to the last changePan, default to false |
immediate | (optional) apply transpostion without smoothing, default to false |
Panning note from left to right Example:
function changeVolume | ( | voiceId | , |
gain | , | ||
relative | , | ||
immediate | |||
) |
changes a voice's volume.
N.B.: the changeVolume() gain will be applied on top of other changes made using fade()
voiceId | id of the voice to be transposed |
gain | linear gain to be applied between 0 and 1 |
relative | (optional) specify if the transposition is relative to the last changeVolume, default to false |
immediate | (optional) apply transpostion without smoothing, default to false |
function changeVolumedB | ( | voiceId | , |
dBGain | , | ||
relative | , | ||
immediate | |||
) |
change the volume of specific voice in decibels.
N.B.: the changeVolume() gain will be applied on top of other changes made using fade()
voiceId | id of the voice to be transposed |
dBgain | gain to be applied in decibels |
relative | (optional) specify if the transposition is relative to the last changeVolumedB, default to false |
immediate | (optional) apply transpostion without smoothing, default to false |
Example:
function setSampleOffset | ( | voiceId | , |
value | |||
) |
changes a sample starting point in milliseconds.
if the oscillator is in streaming mode then the offset will be clipped according to streaming preload preferences
voiceId | id of the voice to apply the samplestart |
value | offset in milliseconds in the sample |
function fadeout | ( | voiceId | , |
duration | , | ||
killVoice | , | ||
reset | , | ||
layer | |||
) |
starts a volume fade-out.
N.B.: the fade volume will be applied on top of other changes made using changeVolume()
voiceId | the voice id to fade-out |
duration | the fade-in duration ms |
killVoice | kill the voice at the end of the fade-out if true |
reset | make the fade start at 1 instead of the current fade value (if a fade in ongoing) |
layer | optional layer id |
function fadein | ( | voiceId | , |
duration | , | ||
reset | , | ||
layer | |||
) |
starts a volume fade-in for a specific voice.
N.B.: the fade volume will be applied on top of other changes made using changeVolume()
voiceId | the voice id to fade-in |
duration | the fade-in duration in ms |
reset | make the fade start at 0 instead of the current fade value (if a fade in ongoing) |
layer | optional layer id |
Example:
function fade | ( | voiceId | , |
targetValue | , | ||
duration | , | ||
layer | |||
) |
starts a volume fade.
N.B.: the fade volume will be applied on top of other changes made using changeVolume()
voiceId | the voice id to fade-in |
targetValue | the volume target to reach |
duration | the fade duration in ms |
layer | optional layer id |
function fade2 | ( | voiceId | , |
startValue | , | ||
targetValue | , | ||
duration | , | ||
layer | |||
) |
starts a volume fade.
N.B.: the fade volume will be applied on top of other changes made using changeVolume()
voiceId | the voice id to fade-in |
startValue | the initial ramp volume |
targetValue | the volume target to reach |
duration | the fade duration in ms |
layer | optional layer id |