programmering:static-on-the-radio2-code
var ran_factor1=10; var ran_factor2=5; var fill_trans=100; var thick=3; var t; function setup() { createCanvas(600,600); noStroke(); fill(235,fill_trans); t=1; } function draw() { var i,j,k; t++; background(0); k_max=0.1*(t%8+random(10,12)); for (k=0; k<k_max; k++) { for (i=2*thick; i<width; i+=2*thick) { for (j=2*thick; j<height; j+=2*thick) { if (random(2)<1) { rect(i,j,k+random(ran_factor1),k+random(ran_factor2)) } else { ellipse(i,j,k+random(ran_factor1),k+random(ran_factor2)); } } } } }
programmering/static-on-the-radio2-code.txt · Last modified: 2023/10/21 19:19 by 127.0.0.1