skip deleted elements in tables

This commit is contained in:
Matthias Hochsteger 2023-02-08 16:18:01 +01:00
parent ca88e90a31
commit cec87bb2ff

View File

@ -2421,6 +2421,7 @@ namespace netgen
[&](auto & table, ElementIndex ei) [&](auto & table, ElementIndex ei)
{ {
const Element & el = (*this)[ei]; const Element & el = (*this)[ei];
if(el.IsDeleted()) return;
if (dom == 0 || dom == el.GetIndex()) if (dom == 0 || dom == el.GetIndex())
{ {
if (el.GetNP() == 4) if (el.GetNP() == 4)
@ -2742,6 +2743,7 @@ namespace netgen
for (ElementIndex ei : elsonpoint[pi]) for (ElementIndex ei : elsonpoint[pi])
{ {
const Element & el = VolumeElement(ei); const Element & el = VolumeElement(ei);
if(el.IsDeleted()) continue;
if (dom == 0 || el.GetIndex() == dom) if (dom == 0 || el.GetIndex() == dom)
{ {