There is a Noise UGen:
Noisehttp://chuck.cs.princeton.edu/doc/program/ugen_full.html#noise
Having said that,this shouldn't be any different from what you're
explaining:
Step randomValue => blackhole;
fun void makeNoise() {
while (true) {
Math.rand2f(0.0,1.0) => randomValue.next;
1::samp => now;
}
}
spork ~ makeNoise();
while (true) {
<<< "random: ", randomValue.last() >>>;
1::second => now;
}
If you'd want smoother transitions between the random values, use an
Envelope instead of Step and wait a it longer than samp between values. But
I guess the Noise UGen is what you're after. :)
/Stefan
On Sun, Sep 26, 2010 at 12:44 PM, Thomas Girod
I didn't find any CNoise ugen - at least in ChucK online documentation. Are there any other extra ugens I can install ?
As for your other suggestion, this is not what I'm looking for. What you are describing is a random walk with a delay of X. What I need is a continuous change and a "freq" parameter that allows me to say how fast this continuous change is happening.
tom
On Sat, Sep 25, 2010 at 11:57:36AM -0400, Andrew C. Smith wrote:
There's a CNoise UGen, right? I believe that's what you're looking for. Otherwise, you can always spork a shred that gets a random value after every specified duration.
Let me know if that explanation didn't make sense and I can sketch up an example.
Andrew
On Sep 25, 2010, at 4:05 AM, Thomas Girod wrote:
Hi there.
I am looking for some kind of "random lfo" to change a parameter continuously and randomly. I remember there is a UGen called "LFNoise2" to do that in SuperCollider.
How can I do that with ChucK ?
thanks
tom _______________________________________________ chuck-users mailing list chuck-users@lists.cs.princeton.edu https://lists.cs.princeton.edu/mailman/listinfo/chuck-users
_______________________________________________ chuck-users mailing list chuck-users@lists.cs.princeton.edu https://lists.cs.princeton.edu/mailman/listinfo/chuck-users
-- Release me, insect, or I will destroy the Cosmos!