From f17702c66abba1d6dfbe99a218372860d61d3d74 Mon Sep 17 00:00:00 2001 From: tpaviot Date: Mon, 2 Nov 2020 17:20:20 +0100 Subject: [PATCH] [g++-warning-fix] Fix sign comparison, unused function, unused variables in IfcGeomShapes.cpp --- src/ifcgeom/IfcGeomShapes.cpp | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) diff --git a/src/ifcgeom/IfcGeomShapes.cpp b/src/ifcgeom/IfcGeomShapes.cpp index ef3146df5f..dd97364bbe 100644 --- a/src/ifcgeom/IfcGeomShapes.cpp +++ b/src/ifcgeom/IfcGeomShapes.cpp @@ -1302,26 +1302,6 @@ namespace { } } - void segment_tiny_edges(const TopoDS_Wire& wire, std::vector& wires, double eps) { - std::vector sorted_edges; - sort_edges(wire, sorted_edges); - - bool segment_next = true; - - BRep_Builder B; - - for (const auto& e : sorted_edges) { - GProp_GProps prop; - BRepGProp::LinearProperties(e, prop); - const double l = prop.Mass(); - if (l < eps || segment_next) { - wires.emplace_back(); - B.MakeWire(wires.back()); - segment_next = l < eps; - } - B.Add(wires.back(), e); - } - } // #939: a closed loop causes failed triangulation in 7.3 and artefacts // in 7.4 so we break up a closed wire into two equal parts. @@ -1335,12 +1315,11 @@ namespace { } BRep_Builder B; - double u, v; wires.emplace_back(); B.MakeWire(wires.back()); - for (int i = 0; i < sorted_edges.size(); ++i) { + for (uint i = 0; i < sorted_edges.size(); ++i) { if (i == sorted_edges.size() / 2) { wires.emplace_back(); B.MakeWire(wires.back());