Author: Carlos Lopez <genet...@gmail.com>
Date:   Mon Aug 13 12:33:49 2012 +0200

Layer_Polygon: add support for winding style

---

 synfig-core/src/synfig/layer_polygon.cpp |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/synfig-core/src/synfig/layer_polygon.cpp 
b/synfig-core/src/synfig/layer_polygon.cpp
index c46f1a2..5517c2e 100644
--- a/synfig-core/src/synfig/layer_polygon.cpp
+++ b/synfig-core/src/synfig/layer_polygon.cpp
@@ -236,7 +236,15 @@ Layer_Polygon::accelerated_cairorender(Context 
context,cairo_surface_t *surface,
                cairo_set_operator(subcr, CAIRO_OPERATOR_CLEAR);
        else
                cairo_set_operator(subcr, CAIRO_OPERATOR_OVER);
-
+       switch(winding_style)
+       {
+               case WINDING_NON_ZERO:
+               cairo_set_fill_rule(subcr, CAIRO_FILL_RULE_WINDING);
+               break;
+               default:
+               cairo_set_fill_rule(subcr, CAIRO_FILL_RULE_EVEN_ODD);
+               break;
+       }
        cairo_fill(subcr);
        cairo_restore(subcr);
        


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Synfig-devl mailing list
Synfig-devl@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/synfig-devl

Reply via email to