Submit
Browse
Anonymous
Login
RSS
SuperCollider Code
Fork Code: Lamento
name
code content
( s.options.memSize_(16384); s.reboot; ) ( s.waitForBoot({ var parser = TheoryNoteParser.new; SynthDef(\pad, { | out = 0, freq = 440, gate=1, a = 0.1, s = 3, r = 1| var freqs = { freq * LFNoise2.kr(freq:1,mul:0.01,add:1) }!24; var gen = LFSaw.ar(freq:freqs) * 0.1; var fmod = 1; //var fmod = LFCub.kr(freq:1/12).range(1, LFNoise2.kr(freq:1).range(6,7)); // sharper sound var rqmod = LFNoise2.kr(freq:1/8).range(0.1,1.0); var modspeed = 1/s; //var modspeed = 10; // tremolo sound //var modspeed = 10k*LFNoise2.ar(freq:4/s); // wobble sound (works best with sharper sounding pad) var snd = RLPF.ar(in:gen, freq:SinOsc.kr(modspeed).range(freqs*0.8, freqs*1.2) * fmod, rq:rqmod); var env = EnvGen.ar(Env.new(levels:[0,1,1,0], times:[a, s, r]), gate, doneAction:2); Out.ar(bus:out, channelsArray:env*Splay.ar(snd)); }).add; SynthDef(\flute, { | out = 0, freq = 440, amp = 1.0, a = 0.1, r = 0.1| //var fmod = 1; // clean //var fmod = LFCub.kr(freq:1/12).range(1, LFNoise2.kr(freq:12.0).range(1,1.1)); // tone deaf flute var fmod = LFCub.kr(freq:1/12).range(1, LFNoise2.kr(freq:12.0).range(1,1.02)); // flute-like sound var env = EnvGen.ar(Env.perc(a, r), levelScale:0.5, doneAction:2); var snd = SinOsc.ar(freq * fmod)!2; Out.ar(bus:out, channelsArray:(env*(amp*snd).tanh)); }).add; s.sync; p = Pbind( \instrument, \pad, \freq, Pseq([ Pseq([ "c2 g3 eb4 g4", ].collect({|el| parser.asMidi(el).midicps}), 1), Pseq([ "g2 g3 d4 f4 g4", "c3 g3 eb4 g4 c5", "f2 f4 ab4 c5 eb5", "eb2 c4 eb4 g4", "g2 d4 f4 g4 b4 d5", "ab2 c4 eb4 ab4", "f2 c4 f4 g4 ab4 f5", "c2 g3 eb4 g4 eb5", ].collect({|el| parser.asMidi(el).midicps}), inf)], 1), \dur, Pseq([5],inf), \s, Pkey(\dur), \a, 0.4 ); q = Pbind( \instrument, \flute, \freq, Pxrand(parser.asMidi("c5 eb5 g5 bb5 c6").midicps ++ [Rest(), Rest()], inf), \dur, Pbrown(lo:0.1,hi:1.0, step:0.125, length:inf), \a, Pkey(\dur)*0.8, \amp, Pseq([ Pseq((((1..16)/16)*0.5), 1), Pbrown(lo:0.3,hi:0.6,step:0.1,length:inf)], inf )); e = Ptpar([0.0, p, 8*5.0, q]).play; }); )
code description
( Requires the theory quark from https://github.com/shimpe/theoryquark ) Moments before life support was to fail, a supercollider satellite was ejected into deep space lamenting their brave but foolish undertaking. Eons later it still floats in empty space, sole witness of times long gone by. To install the quark, just unpack it in the directory that opens when you open scide -> "file menu" -> "open user support directory" and then restart scide (or recompile the class library using the "language" -> "recompile class library" menu)
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