We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Can anyone suggest me how to rotate the arc about the red dot ? Run it your would see the red dot
void setup() {
size(400, 400);
}
int i=0;
void draw() {
background(-1);
// ellipseMode(RADIUS);
translate(mouseX, mouseY);
noFill();
stroke(0);
strokeWeight(20);
rotate(radians(i));
arc(0, 0, 100, 100, 0, PI-PI/9);
fill(255, 0, 0);
noStroke();
ellipse(50, 0, 10, 10);
i++;
}
Answers
Just add
translate(-50, 0);
before the call to arc().Thanks PhiLho :)