I need help with my project!!!
in
Programming Questions
•
11 months ago
So far I have written a code for my project that is almost what i want it to do there are just some minor problems. I would like to be able to draw on the yellow circle but for some reason the circles wont draw on the bigger circle, my second problem is when you drag the mouse and draw circles if you draw to fast it has a delay and you get white spaces I would prefer to just have one solid line of black. If anyone knows how to solve these problems it would be greatly appreciated.
This is my code so far:
void setup()
{
size(640, 480);
fill (0);
background(255);
}
void draw()
{
// only draw when mouse is pressed
fill(0);
if(mousePressed) ellipse(mouseX, mouseY, 5, 5);
fill(246, 255, 2);
ellipse (320, 240, 300, 300);
}
// only clear background when key is pressed
void keyPressed() {
background(255);
}
1