[OpenSCAD] Visually and by inspecting code: surface looks perfect - But: "Object may not be a valid 2-manifold and may need repair"

Ed Nisley ed.nisley at pobox.com
Mon May 18 16:30:52 EDT 2015

On 05/18/2015 02:51 PM, kaefert at gmail.com wrote:
> something wrong in my code

It's not exactly *wrong*, but the order in which you specify the points 
of a polygon / polyhedron determine which way the surface normals point:


"When looking at the face from the outside inwards, the points must be 
clockwise. You can rearrange the order of the points or the order they 
are referenced in each tuple. [...] Note that if your polygons are not 
all oriented the same way OpenSCAD will either print an error or crash 

Given the way that you're generating the points, at least some of the 
polyhedrons may be wound backwards.

The reason this doesn't show up in thrown-together mode may be due to 
the way the polyhedrons combine: everything looks fine from the outside, 
but some inside (invisible) faces wind backwards. Perhaps assembling one 
polyhedron at a time will be productive.

Using Meshlab (or something similar) to check your work may also help 
pin this down.

It's a nice-looking prop, though!


More information about the Discuss mailing list