Skip to content
Snippets Groups Projects
Commit 08991979 authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

fix opti crash with Delaunay algo (forgot to classify new vertices in correct region!)
parent 8866d942
No related branches found
No related tags found
No related merge requests found
// $Id: meshGRegionDelaunayInsertion.cpp,v 1.15 2007-02-03 13:06:44 geuzaine Exp $ // $Id: meshGRegionDelaunayInsertion.cpp,v 1.16 2007-02-14 11:07:02 geuzaine Exp $
// //
// Copyright (C) 1997-2007 C. Geuzaine, J.-F. Remacle // Copyright (C) 1997-2007 C. Geuzaine, J.-F. Remacle
// //
...@@ -497,7 +497,7 @@ void insertVerticesInRegion (GRegion *gr) ...@@ -497,7 +497,7 @@ void insertVerticesInRegion (GRegion *gr)
bool inside = worst->tet()->invertmapping(center,uvw); bool inside = worst->tet()->invertmapping(center,uvw);
if (inside) if (inside)
{ {
MVertex *v = new MVertex (center[0],center[1],center[2]); MVertex *v = new MVertex (center[0],center[1],center[2], worst->onWhat());
v->setNum(NUM++); v->setNum(NUM++);
double lc1 = double lc1 =
(1-uvw[0]-uvw[1]-uvw[2])*vSizes[worst->tet()->getVertex(0)->getNum()] + (1-uvw[0]-uvw[1]-uvw[2])*vSizes[worst->tet()->getVertex(0)->getNum()] +
...@@ -516,7 +516,7 @@ void insertVerticesInRegion (GRegion *gr) ...@@ -516,7 +516,7 @@ void insertVerticesInRegion (GRegion *gr)
} }
else else
{ {
gr->mesh_vertices.push_back(v); v->onWhat()->mesh_vertices.push_back(v);
} }
} }
else else
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment