+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// 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.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
// File: ShHealOper_CloseContour.cxx
// Created: 20.04.04 11:36:01
// Author: Galina KULIKOVA
-// Copyright: Airbus Industries 2004
#include <ShHealOper_CloseContour.hxx>
#include <BRep_Tool.hxx>
#include <ShapeBuild_Edge.hxx>
#include <TopExp_Explorer.hxx>
+
//=======================================================================
//function : ShHealOper_CloseContour()
//purpose : Constructor
//=======================================================================
-
ShHealOper_CloseContour::ShHealOper_CloseContour (const TopoDS_Shape& theShape )
{
Init(theShape);
}
+
//=======================================================================
//function : Init
//purpose :
//=======================================================================
-
void ShHealOper_CloseContour::Init(const TopoDS_Shape& theShape)
{
ShHealOper_Tool::Init(theShape);
myMaxTolerance = 1.0;
TopExp::MapShapesAndAncestors(theShape,TopAbs_EDGE,TopAbs_FACE,myMapEdgesFace);
}
+
//=======================================================================
//function : Perform
//purpose :
//=======================================================================
-
Standard_Boolean ShHealOper_CloseContour::Perform(const TopTools_SequenceOfShape& theSeqEdges,
const Standard_Boolean theModeVertex,
const Standard_Boolean theModeFixGapsCurves)
return myDone;
}
+
//=======================================================================
//function : Perform
//purpose :
//=======================================================================
-
Standard_Boolean ShHealOper_CloseContour::Perform(const TopoDS_Wire& theWire,
const Standard_Boolean theModeVertex,
const Standard_Boolean theModeFixGapsCurves)
build(asewd);
return myDone;
}
+
//=======================================================================
//function : Build
//purpose :
//=======================================================================
-
void ShHealOper_CloseContour::build(Handle(ShapeExtend_WireData)& theSewd)
{
TopTools_SequenceOfShape aCommonFaces;
}
return;
}
+
//=======================================================================
//function : checkGaps
//purpose :
//=======================================================================
-
Standard_Boolean ShHealOper_CloseContour::fixGaps(const Handle(ShapeExtend_WireData)& theWire,
const TopTools_SequenceOfShape& theCommonFaces)
{
//function : checkOneFace
//purpose :
//=======================================================================
-
Standard_Boolean ShHealOper_CloseContour::checkOneFace(const Handle(ShapeExtend_WireData)& theSewd,
TopTools_SequenceOfShape& theCommonFaces) const
{
-
TopTools_IndexedMapOfShape amapfaces;
TopoDS_Edge aEdge1 = theSewd->Edge(1);
Standard_Boolean isOneFace = myMapEdgesFace.Contains(aEdge1 );
theCommonFaces.Append(aF);
}
}
- return isOneFace;
+ return isOneFace;
}
+
//=======================================================================
//function : buildEdge
//purpose :
//=======================================================================
-
void ShHealOper_CloseContour::buildEdge(const TopoDS_Edge& aE1,
const TopoDS_Edge& aE2,
const TopTools_SequenceOfShape& theCommonFaces)
myFreeEdges.Append(edge);
}
}
+
//=======================================================================
//function : UpdateWire
//purpose :
//=======================================================================
-
void ShHealOper_CloseContour::updateWire (Handle(ShapeExtend_WireData)& sbwd)
{
Standard_Integer i=1;