Smol or mid-sized snippets of SuperCollider code that start in SuperCollider's Workspace Emacs buffer from scratch.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

32 lines
695 B

(
var scale = Scale.zhi;
10.do{ arg i;
{
var snd, trig, freq, decaytime, envspec, env, noise;
trig = Impulse.ar(
freq: i * 0.083 * rrand(0.8, 1.2),
phase: 100.rand*0.01);
envspec = Env.perc(
attackTime: 0.001,
releaseTime: rrand(0.001, 0.1),
level: LFNoise0.ar(100).range(0,1));
env = EnvGen.ar(
envelope: envspec,
gate: trig);
noise = BrownNoise.ar * env;
freq = (scale.degrees+60).choose.midicps * [0.5,1,2].choose;
decaytime = rrand(0.01,2);
snd = Ringz.ar(
in:noise,
freq: freq,
decaytime: decaytime,
mul:0.015);
snd = snd.dup; // mono on both speakers.
snd; // lastline = what functions returns = output for .play
}.play;
}
)