#### Howdy, Stranger!

We are about to switch to a new forum software. Until then we have removed the registration on this forum.

# using multiple arcs but the result looks

edited June 2016

So I'm trying to basically draw an ellipse with gaps in between the arcs, but the results I'm getting look very ugly. Is this a bug or am I doing something wrong? I get these results in p5 but in processing as well, especially the smaller it is, the uglier. I thought smooth() would fix it, but it sometimes makes it worse.

these are some of the results:

code:

``````void setup() {
size(600,600);
}

void draw() {
noFill();
translate(width/2, height/2);
drawEyeArcs(0,0, 50, 12);
}

void drawEyeArcs(int x, int y, int size, int segments) {

// we draw double the segments, because we want to skip each odd one
segments *= 2;

for (int i = 0; i < segments; i++) {
if (i % 2 == 1) {
float start = TWO_PI / segments * i;
float end = TWO_PI / segments * (i + 1);
arc(0, 0, size, size, start, end);
}
}
}
``````
Tagged:

• edited June 2016

Just guessing, but if you make size a float not an integer, does that help?

• edited June 2016

No it doesn't. Maybe it's just the lack of resolution at small circle sizes? It looks fine when the circle is big.

• Does smooth() help? What about noLoop()?

• @koogs smooth seems to make it worse. noLoop looks a lot better (although still jaggy) but I need to loop :D

@fuzzySi yea I noticed that big circles are fine. But I can't be the first to notice this, right? I wonder if there's a fix :)

Why do you have0,0 as center? Do you use pishMatrix()? Or translate()?

Canyou post the entire code?

Does it look better with a bigger radius?

You need background at start of draw()