mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-09 21:53:40 +00:00
#3429 Fix b operand non-planar face check
This commit is contained in:
@@ -467,13 +467,19 @@ int IfcGeom::util::eliminate_touching_operands(double prec, const TopoDS_Shape &
|
|||||||
|
|
||||||
// Check if any of the faces in b are non-planar, which is
|
// Check if any of the faces in b are non-planar, which is
|
||||||
// not supported by this quick check.
|
// not supported by this quick check.
|
||||||
|
bool non_planar = false;
|
||||||
for (int i = 1; i <= b_faces.Extent(); ++i) {
|
for (int i = 1; i <= b_faces.Extent(); ++i) {
|
||||||
auto surf = BRep_Tool::Surface(TopoDS::Face(b_faces(i)));
|
auto surf = BRep_Tool::Surface(TopoDS::Face(b_faces(i)));
|
||||||
if (surf->DynamicType() != STANDARD_TYPE(Geom_Plane)) {
|
if (surf->DynamicType() != STANDARD_TYPE(Geom_Plane)) {
|
||||||
continue;
|
non_planar = true;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (non_planar) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
TopTools_IndexedMapOfShape b_vertices;
|
TopTools_IndexedMapOfShape b_vertices;
|
||||||
TopExp::MapShapes(b, TopAbs_VERTEX, b_vertices);
|
TopExp::MapShapes(b, TopAbs_VERTEX, b_vertices);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user