mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-19 14:41:25 +00:00
Fix #4273 ignore degenerate triangles in mesher output
This commit is contained in:
@@ -129,6 +129,11 @@ void ifcopenshell::geometry::OpenCascadeShape::Triangulate(ifcopenshell::geometr
|
|||||||
triangles(i).Get(n3, n2, n1);
|
triangles(i).Get(n3, n2, n1);
|
||||||
else triangles(i).Get(n1, n2, n3);
|
else triangles(i).Get(n1, n2, n3);
|
||||||
|
|
||||||
|
if (dict[n1] == dict[n2] || dict[n2] == dict[n3] || dict[n3] == dict[n1]) {
|
||||||
|
Logger::Warning("Mesher generated a degenerate triangle, ignoring");
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
/* An alternative would be to calculate normals based
|
/* An alternative would be to calculate normals based
|
||||||
* on the coordinates of the mesh vertices */
|
* on the coordinates of the mesh vertices */
|
||||||
/*
|
/*
|
||||||
|
|||||||
Reference in New Issue
Block a user