Submit
Browse
Anonymous
Login
RSS
SuperCollider Code
Fork Code: Re: network of loosely connected nodes (now working)
name
code content
( Ndef(\nodeTest, { // the input // var input = Impulse.ar([1, 3, 5].reciprocal * 1, phase: [0, 0.25, 0.5]).sum; //var input = Impulse.ar([2, 3], phase: [0, 0.25]).sum; // var input = Select.ar(Line.kr(0, 1, 10) * SinOsc.ar(0.01).range(0, 1), [Impulse.ar([0.2, 0.3], phase: [0, 0.25]).sum, LocalIn.ar(1)]); var input = Select.ar(Line.kr(0, 1, 10), [Impulse.ar(0.134), LocalIn.ar(1)]); // the nodes, each takes its predecessor as input and estimates the duration between two events. var nodes = (1..20).inject([input], {|last, item| var dur = Gate.ar( Timer.ar(TDelay.ar(last.first, Rand(1, 4))), last.first ); [TDuty.ar( dur.lag(20), TDelay.ar(last.first, dur.lag(20)), 1 )] ++ last }); LocalOut.ar(nodes.first); // add a pitch to each nodes = nodes.collect{|node, i| SinOsc.ar((500 + (i*250)), 0.9pi) // * Decay2.ar(node, 0.01, 0.2) * EnvGen.ar(Env.perc(0.0001, 0.1), gate: node) * 2 * (25-i) * 0.01}; // splay in stereo field //nodes.sum!2; Splay.ar(nodes)// + (SinOsc.ar(2000) * Decay2.ar(input, 0.01, 0.2) * 0.1); }).play )
code description
Idea: network of loosely connected nodes. Each node has a dedicated pulse rate / phase. Inducing an irregular trigger signal influences the nodes to (gradually) adapt their pulsation freq (and phase?) to the one of the input. sound example: https://soundcloud.com/lfsaw/sync-weakconnection-tduty-time
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