[Gmsh] Something wrong with edge loop

Peter Wainwright peter.wainwright at ieee.org
Mon Mar 2 19:11:07 CET 2009


Hi,

I'm importing a STEP model, generated using a C++ program using
OpenCASCADE, consisting of triangular NURBS patches.  Of course, these
are really rectangular but each has one degenerate edge.

I got a lot of errors "Something wrong with edge loop".  It turns out
that GEdgeLoop::GEdgeLoop(const std::list<GEdge*> &cwire) will often
miss the degenerate edge.  For example, if the edge list contains AB,
BC, CA, CC in that order, then the edge loop will close as AB+BC+CA and
CC will be skipped.  We would fall through to the end of nextOne(),
which should never happen.

Thus nextOne() should check for a degenerate edge and process it before
moving on (in the same way that it already checks for seams). I've
attached a patch which does this.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: gmsh-2.3.1-degen.patch
Type: text/x-patch
Size: 1106 bytes
Desc: not available
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20090302/bd99728b/attachment.patch>