xxxxxxxxxx
51
function setup() {
degrees();
createCanvas(500, 500);
margex = width / 5;
margey = height / 5;
framex = width - margex;
framey = height - margey;
centerx = width / 2;
centery = height / 2;
}
function draw() {
background(mouseX, mouseY, 225);
//white circle//
fill(225, mouseX, mouseY);
noStroke();
ellipse(centerx, centery, framex, framey);
//black half//
fill(mouseY, 225, mouseX);
arc(centerx, centery, framex, framey, PI + HALF_PI, HALF_PI);
//small white//
fill(225, mouseX, mouseY);
ellipse(centerx, centery - margey, framex / 2, framey / 2);
//small black//
fill(mouseY, 225, mouseX);
ellipse(centerx, centery + margey, framex / 2, framey / 2);
//smaller black//
fill(mouseY, 225, mouseX);
ellipse(
centerx,
centery - margey,
framex / 2 - width / 4,
framey / 2 - height / 4
);
//smaller white//
fill(225, mouseX, mouseY);
ellipse(
centerx,
centery + margey,
framex / 2 - width / 4,
framey / 2 - height / 4
);
}