diff options
Diffstat (limited to 'src/fl_arci.cxx')
| -rw-r--r-- | src/fl_arci.cxx | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/fl_arci.cxx b/src/fl_arci.cxx index a9d25f0ed..47db7b3fc 100644 --- a/src/fl_arci.cxx +++ b/src/fl_arci.cxx @@ -86,6 +86,9 @@ void fl_arc(int x,int y,int w,int h,double a1,double a2) { #elif defined(__APPLE_QUARTZ__) a1 = (-a1)/180.0f*M_PI; a2 = (-a2)/180.0f*M_PI; float cx = x + 0.5f*w - 0.5f, cy = y + 0.5f*h - 0.5f; +#ifdef __APPLE_COCOA__ + CGContextSetShouldAntialias(fl_gc, true); +#endif if (w!=h) { CGContextSaveGState(fl_gc); CGContextTranslateCTM(fl_gc, cx, cy); @@ -97,6 +100,9 @@ void fl_arc(int x,int y,int w,int h,double a1,double a2) { CGContextAddArc(fl_gc, cx, cy, r, a1, a2, 1); } CGContextStrokePath(fl_gc); +#ifdef __APPLE_COCOA__ + CGContextSetShouldAntialias(fl_gc, false); +#endif #else # error unsupported platform #endif @@ -136,6 +142,9 @@ void fl_pie(int x,int y,int w,int h,double a1,double a2) { #elif defined(__APPLE_QUARTZ__) a1 = (-a1)/180.0f*M_PI; a2 = (-a2)/180.0f*M_PI; float cx = x + 0.5f*w - 0.5f, cy = y + 0.5f*h - 0.5f; +#ifdef __APPLE_COCOA__ + CGContextSetShouldAntialias(fl_gc, true); +#endif if (w!=h) { CGContextSaveGState(fl_gc); CGContextTranslateCTM(fl_gc, cx, cy); @@ -151,6 +160,9 @@ void fl_pie(int x,int y,int w,int h,double a1,double a2) { CGContextClosePath(fl_gc); } CGContextFillPath(fl_gc); +#ifdef __APPLE_COCOA__ + CGContextSetShouldAntialias(fl_gc, false); +#endif #else # error unsupported platform #endif |
