mirror of
https://github.com/NGSolve/netgen.git
synced 2025-02-02 16:20:33 +05:00
fix 2d edge swapping
This commit is contained in:
parent
fe838fbd75
commit
922a0c5c86
@ -35,6 +35,7 @@ namespace netgen
|
|||||||
|
|
||||||
if (t2 == -1) return false;
|
if (t2 == -1) return false;
|
||||||
if (swapped[t1] || swapped[t2]) return false;
|
if (swapped[t1] || swapped[t2]) return false;
|
||||||
|
if (mesh[t2].IsDeleted()) return false;
|
||||||
|
|
||||||
const int faceindex = mesh[t1].GetIndex();
|
const int faceindex = mesh[t1].GetIndex();
|
||||||
const int surfnr = mesh.GetFaceDescriptor (faceindex).SurfNr();
|
const int surfnr = mesh.GetFaceDescriptor (faceindex).SurfNr();
|
||||||
@ -278,6 +279,7 @@ namespace netgen
|
|||||||
}
|
}
|
||||||
|
|
||||||
const auto sel = mesh[sei];
|
const auto sel = mesh[sei];
|
||||||
|
auto index = sel.GetIndex();
|
||||||
for (int j = 0; j < 3; j++)
|
for (int j = 0; j < 3; j++)
|
||||||
{
|
{
|
||||||
PointIndex pi1 = sel.PNumMod(j+2);
|
PointIndex pi1 = sel.PNumMod(j+2);
|
||||||
@ -286,6 +288,7 @@ namespace netgen
|
|||||||
for (auto sei_other : elements_on_node[pi1])
|
for (auto sei_other : elements_on_node[pi1])
|
||||||
{
|
{
|
||||||
if(sei_other==sei) continue;
|
if(sei_other==sei) continue;
|
||||||
|
if(mesh[sei_other].GetIndex()!=index) continue;
|
||||||
const auto & other = mesh[sei_other];
|
const auto & other = mesh[sei_other];
|
||||||
int pi1_other = -1;
|
int pi1_other = -1;
|
||||||
int pi2_other = -1;
|
int pi2_other = -1;
|
||||||
@ -333,7 +336,7 @@ namespace netgen
|
|||||||
if (mesh[t1].IsDeleted())
|
if (mesh[t1].IsDeleted())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (mesh[t1].GetIndex() != faceindex)
|
if (swapped[t1])
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (multithread.terminate)
|
if (multithread.terminate)
|
||||||
|
@ -6063,7 +6063,11 @@ namespace netgen
|
|||||||
{
|
{
|
||||||
GetSurfaceElementsOfFace (fdi, els_of_face);
|
GetSurfaceElementsOfFace (fdi, els_of_face);
|
||||||
|
|
||||||
if (els_of_face.Size() == 0) continue;
|
if (els_of_face.Size() == 0)
|
||||||
|
{
|
||||||
|
fdi++;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
SurfaceElementIndex firstel = els_of_face[0];
|
SurfaceElementIndex firstel = els_of_face[0];
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user