UGens output valid as a Boolean

It makes sense. Thanks both of you.


{ > 0, [ 0.25),])}.play

Or even


var scale = > 0;

var sine = 0.25) * scale;

var noise = * (1 - scale);, sine + noise);


There are tricks.


Though - be aware that in the cases above ALL UGens are always running. The synth graph is static - but the signal flow isn’t.

all you need to know is here:

It makes sense. Thanks both of you.

In this case how could I do that with this example:

filtervalue freq > 300, [100, 1000]);

“when the freq value go above 300hz the filer value will ramp “exponentialy” from 100 to 1000 hz in 10 seconds”

I found this way:

	filterstart=100; > 300, [0,1]);[1,10],[10],[-7]),gate); > 300, [1,envvv ]);
        snd=, filterstart * ramp);

But to be more specific my problem is there: the freq value comes from an never ending ascending and descending sirene (using LFDNoise3 ). My solution with the code above works only with the rise state (and I have the feeling it’s heavy and not really classy) and I would like this filter ramp behave the same but as opposite when it goes down (ie "when the freq value go below 300hz the filter value will ramp from 1000 to 100 in 10 sec), like a mirror. What could I do?

I’d use LagUD:

	var freq, filt, sine, lowFreq, filtervalue;
	// mouse X for testing
	freq =, 400);
	// just so you can hear the transitions
	sine =, mul: 0.1);
	lowFreq = 100;
	filtervalue freq > 300, [lowFreq, 1000]);
	filtervalue =, 10, 10);
	// filters do NOT like values of 0, so make sure this value is always at least your low value
	filtervalue = filtervalue.max(lowFreq);
	filt =, filtervalue, 0.1);
	[sine, filt]
// move the mouse from left to right  to left to hear the transition of the filter freq

That’s great, thanks.