rsc3/doc-schelp/HelpSource/Classes/Free.schelp

43 lines
691 B
Text

class:: Free
summary:: When triggered, frees a node.
related:: Classes/Pause, Classes/FreeSelf
categories:: UGens>Synth control
Description::
When triggered, frees a node.
classmethods::
method::kr
argument::trig
Trigger input
argument::id
Node to be freed.
Examples::
code::
s.boot;
SynthDef("a", { Out.ar(0, SinOsc.ar(800, 0, 0.2)) }).add;
SynthDef("b", { arg t_t=0; Out.ar(1, PinkNoise.ar(0.3)); Free.kr(t_t, 1001); }).add;
s.sendMsg(\s_new, \a, 1001, 0, 0);
s.sendMsg(\s_new, \b, 1002, 0, 0);
s.sendMsg(\n_set, 1002, \t_t, 1);
s.sendMsg(\s_new, \a, 1001, 0, 0);
s.sendMsg(\n_set, 1002, \t_t, 1);
s.sendMsg(\s_new, \a, 1001, 0, 0);
s.sendMsg(\n_set, 1002, \t_t, 1);
::