Skip to content
Snippets Groups Projects
Commit ddf33280 authored by Tristan Carrier Baudouin's avatar Tristan Carrier Baudouin
Browse files

Lloyd's algorithm corrections

parent 70b4acff
Branches
Tags
No related merge requests found
...@@ -524,16 +524,17 @@ static void Mesh2D(GModel *m) ...@@ -524,16 +524,17 @@ static void Mesh2D(GModel *m)
if(CTX::instance()->mesh.optimizeLloyd){ if(CTX::instance()->mesh.optimizeLloyd){
for(GModel::fiter it = m->firstFace(); it != m->lastFace(); ++it){ for(GModel::fiter it = m->firstFace(); it != m->lastFace(); ++it){
if((*it)->geomType()==GEntity::CompoundSurface || (*it)->geomType()==GEntity::Plane){ if((*it)->geomType()==GEntity::CompoundSurface || (*it)->geomType()==GEntity::Plane){
if((*it)->meshAttributes.method != MESH_TRANSFINITE){
smoothing smm(CTX::instance()->mesh.optimizeLloyd,6); smoothing smm(CTX::instance()->mesh.optimizeLloyd,6);
m->writeMSH("beforeLLoyd.msh"); //m->writeMSH("beforeLLoyd.msh");
smm.optimize_face(*it); smm.optimize_face(*it);
//int rec = 1;//(CTX::instance()->mesh.recombineAll || int rec = ((CTX::instance()->mesh.recombineAll || (*it)->meshAttributes.recombine) && !CTX::instance()->mesh.recombine3DAll);
// (*it)->meshAttributes.recombine); //m->writeMSH("afterLLoyd.msh");
m->writeMSH("afterLLoyd.msh"); if(rec) recombineIntoQuads(*it);
//if(rec) recombineIntoQuads(*it);
//m->writeMSH("afterRecombine.msh"); //m->writeMSH("afterRecombine.msh");
} }
} }
}
/* /*
for(GModel::fiter it = m->firstFace(); it != m->lastFace(); ++it){ for(GModel::fiter it = m->firstFace(); it != m->lastFace(); ++it){
GFace *gf = *it; GFace *gf = *it;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment