From 1e86bc2c59832f3bfcf9381b618f8e4cf4f458e2 Mon Sep 17 00:00:00 2001 From: "mhochsteger@cerbsim.com" Date: Fri, 17 Dec 2021 10:38:15 +0100 Subject: [PATCH] occ - consistent ordering of shapes --- libsrc/occ/occgeom.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/libsrc/occ/occgeom.cpp b/libsrc/occ/occgeom.cpp index 5a81f981..1b84b5ac 100644 --- a/libsrc/occ/occgeom.cpp +++ b/libsrc/occ/occgeom.cpp @@ -1108,8 +1108,9 @@ namespace netgen fsingular = esingular = vsingular = false; // Add shapes - for(auto v : GetVertices(shape)) + for(auto i1 : Range(1, vmap.Extent()+1)) { + auto v = vmap(i1); auto tshape = v.TShape(); if(vertex_map.count(tshape)!=0) continue; @@ -1122,8 +1123,9 @@ namespace netgen vertices.Append(std::move(occ_vertex)); } - for(auto e : GetEdges(shape)) + for(auto i1 : Range(1, emap.Extent()+1)) { + auto e = emap(i1); auto tshape = e.TShape(); auto edge = TopoDS::Edge(e); if(edge_map.count(tshape)!=0) @@ -1137,8 +1139,9 @@ namespace netgen edges.Append(std::move(occ_edge)); } - for(auto f : GetFaces(shape)) + for(auto i1 : Range(1, fmap.Extent()+1)) { + auto f = fmap(i1); auto tshape = f.TShape(); if(face_map.count(tshape)==0) { @@ -1167,8 +1170,9 @@ namespace netgen } - for(auto s : GetSolids(shape)) + for(auto i1 : Range(1, somap.Extent()+1)) { + auto s = somap(i1); auto tshape = s.TShape(); int k; if(solid_map.count(tshape)==0)