Salome HOME
projects
/
modules
/
shaper.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
1b55c21
)
Continue fixing regression with incorrect order of inner wires (sort inner wires...
author
azv
<azv@opencascade.com>
Tue, 3 Mar 2020 09:37:16 +0000
(12:37 +0300)
committer
azv
<azv@opencascade.com>
Tue, 3 Mar 2020 09:38:19 +0000
(12:38 +0300)
src/GeomAlgoAPI/GeomAlgoAPI_SketchBuilder.cpp
patch
|
blob
|
history
diff --git
a/src/GeomAlgoAPI/GeomAlgoAPI_SketchBuilder.cpp
b/src/GeomAlgoAPI/GeomAlgoAPI_SketchBuilder.cpp
index 94c7b718562a7c9202cf8c16bdf21818891ce8f9..dff098d9950e102917290632ebc795427cfea3f6 100644
(file)
--- a/
src/GeomAlgoAPI/GeomAlgoAPI_SketchBuilder.cpp
+++ b/
src/GeomAlgoAPI/GeomAlgoAPI_SketchBuilder.cpp
@@
-255,12
+255,17
@@
void GeomAlgoAPI_SketchBuilder::build(
TopoDS_Face aNewFace;
aBuilder.MakeFace(aNewFace, aPlane, Precision::Confusion());
TopoDS_Face aNewFace;
aBuilder.MakeFace(aNewFace, aPlane, Precision::Confusion());
- // sort wires according to the original edges as well as faces
+ // sort
inner
wires according to the original edges as well as faces
TopTools_ListOfShape aWires;
TopExp_Explorer aWireExp(aFace, TopAbs_WIRE);
for (; aWireExp.More(); aWireExp.Next())
aWires.Append(aWireExp.Current());
TopTools_ListOfShape aWires;
TopExp_Explorer aWireExp(aFace, TopAbs_WIRE);
for (; aWireExp.More(); aWireExp.Next())
aWires.Append(aWireExp.Current());
- sortAreas(aWires, theEdges);
+ if (aWires.Size() > 2) {
+ TopoDS_Shape anOuterWire = aWires.First();
+ aWires.RemoveFirst();
+ sortAreas(aWires, theEdges);
+ aWires.Prepend(anOuterWire);
+ }
// iterate on wires
for (TopTools_ListIteratorOfListOfShape aWIt(aWires); aWIt.More(); aWIt.Next()) {
// iterate on wires
for (TopTools_ListIteratorOfListOfShape aWIt(aWires); aWIt.More(); aWIt.Next()) {