mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-13 02:47:48 +00:00
Use exact topology points at parametric range bounds to guarantee welding #4487
This commit is contained in:
@@ -397,7 +397,10 @@ int IfcGeom::Representation::Triangulation::addVertex(int item_id, int material_
|
||||
if (settings().get<ifcopenshell::geometry::settings::WeldVertices>().get()) {
|
||||
const VertexKey key = std::make_tuple(item_id, material_index, X, Y, Z);
|
||||
typename VertexKeyMap::const_iterator it = welds.find(key);
|
||||
if (it != welds.end()) return it->second;
|
||||
if (it != welds.end()) {
|
||||
// Return index for previously encountered point
|
||||
return it->second;
|
||||
}
|
||||
i = (int)(welds.size() + weld_offset_);
|
||||
welds[key] = i;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user