|
|
From the documentation:
void fl_arc(double x, double y, double r, double start, double end)
Add a series of points to the
current path on the arc of a circle; you can get elliptical paths by
using scale and rotate before calling fl_arc(). The center of the circle is given by x and y, and r is its radius. fl_arc() takes start and end angles that are measured in degrees counter-clockwise from 3 o'clock. If end is less than start then it draws the arc in a clockwise direction.
This infers that the two calls:
fl_arc(0, 0, radius, 90, 180);
fl_arc(0, 0, radius, 180, 90); result in the same drawing - the arc selected is from 9 o'clock clockwise to 12 o'clock. And indeed they do.
I coded: fl_arc(0, 0, radius, 180, 450);
to achieve what I wanted which was to draw an arc clockwise from 12 o'clock to 9 o'clock.
My concern is that this is not properly documented. Should I have drawn two separate arcs from 180 to 360 and 0 to 90?
I also noticed that the code fl_start_polygon(); fl_vector(0,0); fl_arc(0,0, radius, 180, 450); fl_end_polygon();
actually worked to give me the 3/4 of the pie even though it is a concave shape.
Phil.
--
You received this message because you are subscribed to the Google Groups "fltk.general" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkgeneral+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkgeneral/e2082917-db06-413f-a210-3b5393ce5550n%40googlegroups.com.
[ Direct Link to Message ] | |
|
| |