xxxxxxxxxx
90
function setup() {
createCanvas(500, 350);
}
function draw() {
colorMode(RGB);
background(255,255,255);
let h = mouseX;
if (h >355) {
h = h - 360;
}
let s = mouseY;
if (s >255) {
s = s - 360;
}
let l = mouseX;
if (l >130) {
l = l - 300;
}
colorMode (HSL, 360);
strokeWeight(20);
stroke(h + 300,200,l + 50);
line(50,180,0,250);
line(93,180,0,305);
line(136,180,0,360);
line(179,180,0,415);
line(222,180,0, 470);
line(265,180,0,525);
line(253,248,0,600);
line(255,298,0,675);
stroke(h + 200,300,200);
line(260,290,286,340);
line(260,235,322,340);
line(258,180,360,340);
line(292,180,398,340);
line(328,180,436,340);
line(364,180,474,340);
line(400,180,508,340);
line(436,180,546,340);
line(474,180,584,340);
noStroke();
fill(0,0,0);
rect(0,0,15,350);
rect(0,0,500,15);
rect(485,0,15,350);
rect(0,335,500,15);
rect(0,170,500,15);
rect(250,0,15,350);
colorMode(HSL, 360);
noStroke();
fill(h + 100 ,350, l + 100);
rect(30,15,18,155);
rect(63,15,18,155);
rect(93,15,18,155);
rect(126,15,18,155);
rect(159,15,18,155);
rect(192,15,18,155);
rect(225,15,18,155);
fill(h,300, 250);
rect(265,30,220,18);
rect(265,63,220,18);
rect(265,96,220,18);
rect(265,129,220,18);
}