Submit
Browse
Anonymous
Login
RSS
SuperCollider Code
Fork Code: A1
name
code content
//DEFS/////////// //hh ( SynthDef("hihat", {arg out = 0, amp = 0.5, att = 0.5, rel = 0.02, ffreq = 4000, pan = 0; var env, snd; env = Env.perc( attackTime: 1, releaseTime: 0.02, level: amp ).kr(doneAction: 2); snd = WhiteNoise.ar; snd = HPF.ar(in: snd, freq: ffreq, mul: env); Out.ar(out, Pan2.ar(snd, pan)); }).add; ) //snare ( SynthDef("snare", {arg out = 0, amp = 0.3, att = 0.01, sus = 1, rel = 0.08, ffreq = 200, pan = 0; var env, snd; env = Env.perc(att, sus, rel, amp).kr(doneAction: 2); snd = BPF.ar( in: WhiteNoise.ar, freq: ffreq, mul: env ); Out.ar(out, Pan2.ar(snd, pan)); }).add; ) //plucking ( SynthDef("plucking", {arg amp = 0.1, freq = 440, decay = 5, dampen = 0.1; var env, snd; env = Env.linen(0, decay, 0).kr(doneAction: 2); snd = Pluck.ar( in: WhiteNoise.ar(amp), trig: Impulse.kr(0), maxdelaytime: 0.1, delaytime: freq.reciprocal, decaytime: decay, coef: dampen); Out.ar(0, [snd, snd]); }).add; ) //bass ( SynthDef("bass", { arg freq = 440, amp = 0.1, att = 0.1, rel = 2, lofreq = 1000, hifreq = 3000; var env, snd; env = Env.perc( attackTime: att, releaseTime: rel, level: amp ).kr(doneAction: 2); snd = SinOsc.ar(freq: freq * [0.9, 1, 1.2, 0.75], mul: env); snd = LPF.ar( in: snd, freq: LFNoise2.kr(1).range(lofreq, hifreq) ); snd = Splay.ar(snd); Out.ar(0, snd); }).add; ) //PBINDS s.record; s.stopRecording; ( { Pbind( \instrument, "hihat", \dur, Pseq([Rest(1/2), 1/2, 1/2, 1/6, 1/6, 1/6], inf), \att, 2, \rel, 0.001, \ffreq, 500, \pan, Pseq([0.4, -0.4], inf), \amp, 0.1 ).play; 4.wait; Pbind( \instrument, "snare", \dur, Pseq([Rest(2), 2], inf), \att, 0.01, \rel, 0.5, \ffreq, Pseq([1000, 500, 4000, 500], inf), \amp, 1 ).play; ( Pbind( \instrument, "plucking", \freq, Pseq([220, 440, [660, 880, 1020]], inf), \amp, Pseq([0.3, 0.4, 0.1], inf), \decay, 8, \dampen, Pseq([0.09, 0.2, 0.0001], inf), \dur, Pseq([1, 2, 4], inf) ).play; Pbind( \instrument, "bass", \midinote, Pseq([ [30], [], Prand([ [32], [38], ], 1) ], inf ), \dur, Prand([1, 3, 4, 4.5], 4), \att, 0.1, \rel, Pkey(\dur) + 1, \hifreq, 5000, \amp, 0.2 ).play; ) }.fork )
code description
use markdown for formating
category tags
comma separated, i.g. "wild, siren" (do not enter default SC class names, please)
ancestor(s)
comma separated identificators, i.g. "1-C,1-1,1-4M,1-x"
Private?
the code will be accessible by direct url and not visible in public activity
signup to submit public code without captcha
comment of change