X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FShHealOper%2FShHealOper_CloseContour.cxx;h=e99cf60b2c83d333b7dba6944bcc1b04cfec2912;hb=09ece3edc1896e16a412b35810d76411f06d68ec;hp=64749f18c8d27b61aa80658bbc261e92b68387df;hpb=73555c78ebf12a1fdb85157b8e7934ad566ae90a;p=modules%2Fgeom.git diff --git a/src/ShHealOper/ShHealOper_CloseContour.cxx b/src/ShHealOper/ShHealOper_CloseContour.cxx index 64749f18c..e99cf60b2 100644 --- a/src/ShHealOper/ShHealOper_CloseContour.cxx +++ b/src/ShHealOper/ShHealOper_CloseContour.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2023 CEA, EDF, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -6,7 +6,7 @@ // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public // License as published by the Free Software Foundation; either -// version 2.1 of the License. +// version 2.1 of the License, or (at your option) any later version. // // This library is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -136,7 +136,7 @@ void ShHealOper_CloseContour::build(Handle(ShapeExtend_WireData)& theSewd) //checks that all specified edges belong the one face or not. Standard_Boolean isOneFace = checkOneFace(theSewd,aCommonFaces); - //add edge or increase max tolerance in dependance on specified VertexMode. + //add edge or increase max tolerance in dependence on specified VertexMode. //if all edges belong the one face that gap will be closed in the 2D by line //else gap will be closed in the 3D by line. myDone = fixGaps(theSewd,aCommonFaces); @@ -252,10 +252,14 @@ Standard_Boolean ShHealOper_CloseContour::fixGaps(const Handle(ShapeExtend_WireD Standard_Integer ind1 = (ind2 >1 ? ind2 -1 : theWire->NbEdges()); TopoDS_Edge aE1= theWire->Edge(ind1); TopoDS_Edge aE2= theWire->Edge(ind2); - if(!myModeVertex) + if(!myModeVertex) { buildEdge(aE1,aE2,theCommonFaces); - else + myStatistics.AddModif("An edge added to close a wire"); + } + else { myMaxTolerance = RealLast(); + myStatistics.AddModif("Tolerance of vertex increased to close a wire"); + } if(ind2 == ind1) break; } } @@ -268,8 +272,9 @@ Standard_Boolean ShHealOper_CloseContour::fixGaps(const Handle(ShapeExtend_WireD //function : checkOneFace //purpose : //======================================================================= -Standard_Boolean ShHealOper_CloseContour::checkOneFace(const Handle(ShapeExtend_WireData)& theSewd, - TopTools_SequenceOfShape& theCommonFaces) const +Standard_Boolean +ShHealOper_CloseContour::checkOneFace(const Handle(ShapeExtend_WireData)& theSewd, + TopTools_SequenceOfShape& theCommonFaces) const { TopTools_IndexedMapOfShape amapfaces; TopoDS_Edge aEdge1 = theSewd->Edge(1);