[OpenSCAD] Drawing a horn torus and the dreaded "winding order" error

Jez Weston jezweston at yahoo.com
Wed Aug 10 11:15:21 CEST 2011

I've been loving OpenSCAD, but I've come across a problem that took me a while to track down. My geometry would display in CSG, but trying CGAL threw up the dreaded: 
"ERROR: Illegal polygonal object - make sure all polygons are defined with the same winding order. Skipping affected object."

I'm trying to draw a torus. If the major radius is equal to the minor radius (a horn torus), then OpenSCAD throws a wobbly. If they are different, then everything is drawn correctly. So, can anyone reproduce this or is it a problem with my setup?

Here's my (utterly minimal) test code:

x = 1;
rotate_extrude (convexity = 10, $fn = 24)
translate ([ x, 0, 0 ])
circle (r = 1 );
With x=/=1, this works just fine. With x=0.999, it works; with x=0.9999, it doesn't (although the precise value where it starts to throw a wobbly is depends upon the value of $fn).

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rocklinux.net/pipermail/openscad/attachments/20110810/ba81ed65/attachment.html

More information about the OpenSCAD mailing list