You could actually learn something quite important from this point.
There is, of course, a way to do it – but “muting individual lines” is not conceptually rich enough to get you to the answer.
Taking just two steps in the chain, for example:
var sig;
sig = SinOsc.ar(LFNoise0.kr(10).exprange(1, 1000));
sig = SinOsc.ar(310, sig * 3);
A UGen’s output depends on its inputs.
SinOsc.ar(310, sig * 3)
depends on its frequency (310) and its phase (sig * 3). This multiplication in turn depends on sig
and 3. sig
was assigned in the previous line, so all the dependencies are met.
What if you comment out the first sig = ...
?
What is sig
in this case?
The value of a variable that hasn’t been assigned anything is nil
.
So the phase input becomes nil * 3
.
What should one expect the result of this operation to be?
It’s a nonsense operation. You can’t do multiplication with only one number. So it produces an error. (Here… You said “without the interpreter giving error messages” without the content of the errors – but errors are not just an inconvenience to be sidestepped – they give you useful information about what went wrong! Dig into that a bit more.)
So then the answer is – to “mute a line,” don’t just delete it. Replace the UGen with another value that makes sense for the input. Often that will be 0 or 1.
var sig;
sig = 0; // SinOsc.ar(LFNoise0.kr(10).exprange(1, 1000));
sig = SinOsc.ar(310, sig * 3);
When you delete a patch cable in VCV or Reaktor, this isn’t “no value” for the input – the input takes a neutral value. Likewise in SC, there needs to be a neutral value. “No input” is likely to cause a problem. Neutral values will work. (Most UGens have default values, so SinOsc.ar
actually works even with “no” frequency – because there’s nothing overriding the default frequency. But SinOsc.ar(nil)
– explicitly requesting no value – gives you “ERROR: SinOsc arg: ‘freq’ has bad input: nil”.)
hjh