Commit 7f8d900c authored by Jean-François Remacle's avatar Jean-François Remacle

pok

Merge branch 'master' of http://gitlab.onelab.info/gmsh/gmsh
parents 2a1f1e56 555105e5
......@@ -1807,8 +1807,6 @@ static bool buildConsecutiveListOfVertices(
if(seam && seam_the_first) {
coords = ((*it)._sign == 1) ? mesh1d_seam : mesh1d_seam_reversed;
found = (*it);
Msg::Info(
"This test case would have failed in previous Gmsh versions ;-)");
}
else {
coords = ((*it)._sign == 1) ? mesh1d : mesh1d_reversed;
......@@ -2758,9 +2756,7 @@ static double TRIANGLE_VALIDITY(GFace *gf, MTriangle *t)
SVector3 d2(t->getVertex(2)->x() - t->getVertex(0)->x(),
t->getVertex(2)->y() - t->getVertex(0)->y(),
t->getVertex(2)->z() - t->getVertex(0)->z());
SVector3 c = crossprod(d1, d2);
return dot(N, c);
}
......@@ -2870,15 +2866,18 @@ void meshGFace::operator()(GFace *gf, bool print)
Msg::Warning("Surface %d consists of no elements", gf->tag());
}
if(algoDelaunay2D(gf) && !isMeshValid(gf)) {
Msg::Warning(
"Delaunay based mesher failed on surface %d --> moving to meshadapt",
gf->tag());
// test validity for non-Gmsh models (currently we cannot reliably evaluate
// the normal on the boundary of surfaces with the Gmsh kernel)
if(gf->getNativeType() != GEntity::GmshModel &&
algoDelaunay2D(gf) && !isMeshValid(gf)) {
Msg::Warning("Delaunay-based mesher failed on surface %d -> moving to MeshAdapt",
gf->tag());
deMeshGFace killer;
killer(gf);
gf->setMeshingAlgo(1);
(*this)(gf, print);
}
}
static bool getGFaceNormalFromVert(GFace *gf, MElement *el, SVector3 &nf)
......
......@@ -1502,15 +1502,15 @@ void bowyerWatsonFrontal(GFace *gf, std::map<MVertex *, MVertex *> *equivalence,
}
// nbSwaps = edgeSwapPass(gf, AllTris, SWCR_QUAL, DATA);
char name[245];
sprintf(name, "delFrontal_GFace_%d.pos", gf->tag());
_printTris(name, AllTris.begin(), AllTris.end(), &DATA);
sprintf(name, "delFrontal_GFace_%d_Real.pos", gf->tag());
_printTris(name, AllTris.begin(), AllTris.end(), NULL);
// sprintf(name,"delFrontal_GFace_%d_Layer_Real%d.pos",gf->tag(),ITERATION);
// _printTris (name, AllTris.begin(), AllTris.end(),NULL);
// sprintf(name,"delFrontal_GFace_%d_Layer_%d_Active.pos",gf->tag(),ITERATION);
// _printTris (name, ActiveTris.begin(), ActiveTris.end(), &DATA);
// char name[245];
// sprintf(name, "delFrontal_GFace_%d.pos", gf->tag());
// _printTris(name, AllTris.begin(), AllTris.end(), &DATA);
// sprintf(name, "delFrontal_GFace_%d_Real.pos", gf->tag());
// _printTris(name, AllTris.begin(), AllTris.end(), NULL);
// sprintf(name,"delFrontal_GFace_%d_Layer_Real%d.pos",gf->tag(),ITERATION);
// _printTris (name, AllTris.begin(), AllTris.end(),NULL);
// sprintf(name,"delFrontal_GFace_%d_Layer_%d_Active.pos",gf->tag(),ITERATION);
// _printTris (name, ActiveTris.begin(), ActiveTris.end(), &DATA);
transferDataStructure(gf, AllTris, DATA);
// removeThreeTrianglesNodes(gf);
......
......@@ -1031,7 +1031,6 @@ bool edgeSwapDelProj(MVertex *v1, MVertex *v2, MVertex *v3, MVertex *v4)
SVector3 n1 = t1.getFace(0).normal();
SVector3 n2 = t2.getFace(0).normal();
if(dot(n1, n2) <= 0) {
// printf("OLA !!!\n");
return true;
}
return false;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment