xxxxxxxxxx
function setup() {
createCanvas(windowWidth, windowHeight);
background(0);
//rectMode(CENTER);
}
function draw() {
translate(width/2, height/2);
let s = map(sin(millis()/800), -10, 10, -4000, 4000)
//map(input, von_input, bis_input,von_output, bis_output);
let r = map(sin(millis()/200), -5, 5, 10, PI);
let c = map(sin(millis()/200), -10, 10, 10, 50);
let w = map(sin(millis()/200), -10, 10, 10, 400);
fill(255, 1);
stroke(0, 10);
strokeWeight(5);
translate(s, 0);
rotate(r);
rect(0, 0, w, w);
line(0, 0, 50, 50);
stroke(255);
rotate(millis()/100);
ellipse(0, 0, 100, 100, 10);
strokeWeight(10,10);
stroke(0, 10);
/*Geometry
translate(mouseX, mouseY);
noFill();
stroke(255);
//rotate(millis()/100);
ellipse(0, 0, random(250), random(250));
/*
//triangles
/*
noFill();
stroke(255);
translate(mouseX, mouseY);
rotate(millis()/8000);
triangle(-50, 25, 50, 25, 0, -50);
rotate(PI);
*/
}