pakt00
Built with p5.js and SuperCollider. See /f0blog/pact-februari/
//pakt00 ok - but missing lines from center to start of arc
let index;
let grad;
function setup() {
let div= select('#sketch');
let cnv= createCanvas(div.width, div.height);
cnv.parent('sketch');
frameRate(60);
noFill();
strokeWeight(1);
stroke(255, 255, 255*0.8, 255);
index= 0;
grad= createGraphics(width, height);
grad.noStroke();
for(let r= width; r>0; --r) {
grad.fill(lerpColor(color(255, 255, 0.8*255), color(0, 0, 0), r/width));
grad.ellipse(width*0.5, height*0.5, r*2.0, r*2.0);
}
}
function draw() {
let x= width*0.5;
let y= height*0.5;
let w= width*0.25;
let h= height*0.25;
image(grad, 0, 0);
for(let i= 0; i<120; i++) {
let start= sin((index+i)*0.006+i)*PI;
let end= sin((index+i)*0.0123+i)*2*PI;
if(start<end) {
let r= sin(index*0.01+i)*70+75;
arc(x, y, r*2.0, r*2.0, start, end);
} else {
let r= sin(index*0.01+i)*50.0+55.0;
arc(x+(sin(i*0.21)*w), y+(cos(i*0.2)*h), r*2.0, r*2.0, end, start);
}
}
index++;
}
Ndef(\sines).play
(
Ndef(\sines, {GVerb.ar(Splay.ar(SinOsc.ar([100, 200, 300]+SinOsc.ar([0.11, 0.22, 0.33]), SinOsc.ar([0.1, 0.2, 0.3], 0, 2pi), 0.1+SinOsc.ar([0.01, 0.02, 0.03], 0, 0.05)), SinOsc.ar(SinOsc.ar(SinOsc.ar(0.13, 0, 5, 6), 0, 8, 50), 0, 1, 1), 0.7, SinOsc.ar(1.2, 0, 0.6)), 20, 5, 1, 0.5, 25, 0, 1, 1)})
)
Ndef(\sines).stop