Hz.ModRand
is a parameter modulator
that can be used to drive parameter
changes of one or more parameters in your audio graph. See Hz.LFO
if you wish to produce audio-rate modulation signals for side-chaining.
This example groups a few small examples under on roof. Copy them into your workspace to explore their implementation details.
walks through each of Hz.ModRand's
modes to set the Transpose
parameter of Hz.Osc. Note that the
mode "Random" has no intrinsic period and so it produces a noiselike
effect since it produces a random transpose value frequently.
Also note that we remap the modulator from 0-1 to 0-12 via the
scale
parameter. This is subsequently inverted to obtain specific
semitone values for "RandomChoice" and "RandomDraw" modes.