1 // Copyright (C) 2007-2011 CEA/DEN, EDF R&D, OPEN CASCADE
\r
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
\r
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
\r
6 // This library is free software; you can redistribute it and/or
\r
7 // modify it under the terms of the GNU Lesser General Public
\r
8 // License as published by the Free Software Foundation; either
\r
9 // version 2.1 of the License.
\r
11 // This library is distributed in the hope that it will be useful,
\r
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
\r
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
\r
14 // Lesser General Public License for more details.
\r
16 // You should have received a copy of the GNU Lesser General Public
\r
17 // License along with this library; if not, write to the Free Software
\r
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
\r
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
\r
22 // File: GEOMAlgo_FinderShapeOn1.hxx
\r
23 // Created: Fri Mar 4 10:31:06 2005
\r
24 // Author: Peter KURNEV
\r
26 #ifndef _GEOMAlgo_FinderShapeOn1_HeaderFile
\r
27 #define _GEOMAlgo_FinderShapeOn1_HeaderFile
\r
29 #include <GEOMAlgo_State.hxx>
\r
30 #include <GEOMAlgo_IndexedDataMapOfShapeState.hxx>
\r
31 #include <GEOMAlgo_ShapeAlgo.hxx>
\r
32 #include <GEOMAlgo_ListOfPnt.hxx>
\r
34 #include <TopAbs_State.hxx>
\r
35 #include <TopAbs_ShapeEnum.hxx>
\r
36 #include <TopoDS_Face.hxx>
\r
37 #include <TopoDS_Edge.hxx>
\r
38 #include <TopTools_ListOfShape.hxx>
\r
40 #include <Geom_Surface.hxx>
\r
41 #include <Handle_Geom_Surface.hxx>
\r
42 #include <GeomAdaptor_Surface.hxx>
\r
44 #include <gp_Pnt.hxx>
\r
46 #include <Standard.hxx>
\r
47 #include <Standard_Macro.hxx>
\r
48 #include <Standard_Integer.hxx>
\r
50 //=======================================================================
\r
51 //function : GEOMAlgo_FinderShapeOn1
\r
53 //=======================================================================
\r
54 class GEOMAlgo_FinderShapeOn1 : public GEOMAlgo_ShapeAlgo
\r
58 GEOMAlgo_FinderShapeOn1();
\r
61 virtual ~GEOMAlgo_FinderShapeOn1();
\r
64 void SetSurface(const Handle(Geom_Surface)& aS) ;
\r
67 void SetShapeType(const TopAbs_ShapeEnum aST) ;
\r
70 void SetState(const GEOMAlgo_State aSF) ;
\r
73 void SetNbPntsMin(const Standard_Integer aNb) ;
\r
76 Standard_Integer NbPntsMin() const;
\r
79 void SetNbPntsMax(const Standard_Integer aNb) ;
\r
82 Standard_Integer NbPntsMax() const;
\r
85 const Handle_Geom_Surface& Surface() const;
\r
88 TopAbs_ShapeEnum ShapeType() const;
\r
91 GEOMAlgo_State State() const;
\r
94 virtual void Perform() ;
\r
97 const TopTools_ListOfShape& Shapes() const;
\r
100 const GEOMAlgo_IndexedDataMapOfShapeState& MSS() const;
\r
104 virtual void CheckData() ;
\r
107 void ProcessVertices() ;
\r
110 void ProcessEdges() ;
\r
113 void ProcessFaces() ;
\r
116 void ProcessSolids() ;
\r
119 void InnerPoints(const TopoDS_Face& aF,
\r
120 GEOMAlgo_ListOfPnt& aLP) ;
\r
123 void InnerPoints(const TopoDS_Edge& aE,
\r
124 GEOMAlgo_ListOfPnt& aLP) ;
\r
127 void InnerPoints(const TopoDS_Edge& aE,
\r
128 const Standard_Integer aNbPnts,
\r
129 GEOMAlgo_ListOfPnt& aLP) ;
\r
132 virtual TopAbs_State GetPointState(const gp_Pnt& aP) ;
\r
135 Handle_Geom_Surface mySurface;
\r
136 TopAbs_ShapeEnum myShapeType;
\r
137 GEOMAlgo_State myState;
\r
138 Standard_Integer myNbPntsMin;
\r
139 Standard_Integer myNbPntsMax;
\r
140 GeomAdaptor_Surface myGAS;
\r
141 TopTools_ListOfShape myLS;
\r
142 GEOMAlgo_IndexedDataMapOfShapeState myMSS;
\r