Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
GEOMAlgo_GetInPlace.hxx
Go to the documentation of this file.
1 // Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5 //
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
10 //
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
15 //
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 //
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 //
22 // File: GEOMAlgo_GetInPlace.hxx
23 // Created:
24 // Author: Peter KURNEV
25 
26 #ifndef _GEOMAlgo_GetInPlace_HeaderFile
27 #define _GEOMAlgo_GetInPlace_HeaderFile
28 
29 #include <Standard.hxx>
30 #include <Standard_Macro.hxx>
31 #include <Standard_Integer.hxx>
32 #include <Standard_Real.hxx>
33 #include <Standard_Boolean.hxx>
34 
35 #include <TopAbs_ShapeEnum.hxx>
36 #include <TopoDS_Shape.hxx>
37 
41 
43 #include <GEOMAlgo_GluerAlgo.hxx>
44 #include <GEOMAlgo_Algo.hxx>
46 #include <TopTools_DataMapOfShapeInteger.hxx>
47 #include <TopTools_DataMapOfShapeShape.hxx>
48 
49 
50 //=======================================================================
56 //=======================================================================
57 //class : GEOMAlgo_GetInPlaceIterator
58 //purpose :
59 //=======================================================================
61  public:
65  //Standard_EXPORT
67 
71  //Standard_EXPORT
73 
77  //Standard_EXPORT
78  void Clear() ;
79 
85  //Standard_EXPORT
86  void AppendPair(const GEOMAlgo_CoupleOfShapes& theCS) ;
87 
95  //Standard_EXPORT
96  void Initialize(const TopAbs_ShapeEnum theT1,
97  const TopAbs_ShapeEnum theT2) ;
103  //Standard_EXPORT
104  Standard_Boolean More() const;
105 
109  //Standard_EXPORT
110  void Next() ;
111 
117  //Standard_EXPORT
118  const GEOMAlgo_CoupleOfShapes& Value() const;
119 
120 protected:
121  Standard_Integer myDim;
125 
126 private:
127 };
128 
129 
130 //=======================================================================
136 //=======================================================================
137 //class : GEOMAlgo_GetInPlace
138 //purpose :
139 //=======================================================================
141  public GEOMAlgo_Algo
142 {
143  public:
147  Standard_EXPORT
152  Standard_EXPORT
153  virtual ~GEOMAlgo_GetInPlace();
159  Standard_EXPORT
160  virtual void SetShapeWhere(const TopoDS_Shape& theShape) ;
161 
167  Standard_EXPORT
168  const TopoDS_Shape& ShapeWhere() const;
169 
175  Standard_EXPORT
176  void SetTolMass(const Standard_Real theTol) ;
177 
183  Standard_EXPORT
184  Standard_Real TolMass() const;
185 
191  Standard_EXPORT
192  void SetTolCG(const Standard_Real theTol) ;
193 
199  Standard_EXPORT
200  Standard_Real TolCG() const;
201 
205  Standard_EXPORT
206  virtual void Perform() ;
207 
213  Standard_EXPORT
214  Standard_Boolean IsFound() const;
215 
219  Standard_EXPORT
220  virtual void CheckData() ;
221 
225  Standard_EXPORT
226  virtual void Clear() ;
227 
236  Standard_EXPORT
238 
247  Standard_EXPORT
249  //
264  Standard_EXPORT
265  const TopoDS_Shape &Result();
266 
267 protected:
268  Standard_EXPORT
269  void Intersect() ;
270 
271  Standard_EXPORT
272  void PerformVV() ;
273 
274  Standard_EXPORT
275  void PerformVE() ;
276 
277  Standard_EXPORT
278  void PerformEE() ;
279 
280  void PerformEE(const TopoDS_Shape &theE1, const TopoDS_Shape &theE2);
281 
282  Standard_EXPORT
283  void PerformVF() ;
284 
285  Standard_EXPORT
286  void PerformEF() ;
287 
288  Standard_EXPORT
289  void PerformFF() ;
290 
291  void PerformFF(const TopoDS_Shape &theF1, const TopoDS_Shape &theF2);
292 
293  Standard_EXPORT
294  void FillEdgesOn(const TopoDS_Shape &theShape);
295 
296  Standard_EXPORT
297  void FillFacesOn(const TopoDS_Shape &theShape);
298 
299  Standard_EXPORT
300  void FillSolidsOn(const TopoDS_Shape &theShape);
301 
302  Standard_EXPORT
303  void PerformZF() ;
304 
305  Standard_EXPORT
306  void PerformZZ() ;
307 
308  void PerformZZ(const TopoDS_Shape &theSo1, const TopoDS_Shape &theSo2);
309 
310  Standard_EXPORT
311  void FillImages(const TopoDS_Shape &theShape,
312  const Standard_Boolean IsWhere);
313 
314  void FillImgSimple(const TopoDS_Shape &theShape,
315  const TopAbs_ShapeEnum theSubShapeType,
316  const Standard_Boolean IsWhere);
317 
318  void FillImgComplex(const TopoDS_Shape &theShape,
319  const Standard_Boolean IsWhere);
320 
321  void FillImgComplex(const TopoDS_Shape &theShape,
322  const TopAbs_ShapeEnum theSubShapeType,
323  const Standard_Boolean IsWhere);
324 
325  Standard_EXPORT
326  void CheckGProps() ;
327 
328  Standard_EXPORT
329  void FillShapesIn(const TopoDS_Shape& theS1,
330  const TopoDS_Shape& theS2) ;
331 
332  Standard_EXPORT
333  void FillShapesOn(const TopoDS_Shape& theS1,
334  const TopoDS_Shape& theS2) ;
335 
336  Standard_EXPORT
337  Standard_Boolean CheckCoincidence(const TopoDS_Shape& theS1,
338  const TopoDS_Shape& theS2);
339 
340  Standard_EXPORT
341  Standard_Integer CheckGProps(const TopoDS_Shape& theS);
342 
343  Standard_Boolean CompareGProps
344  (const TopoDS_Shape &theShape1,
345  const TopTools_ListOfShape &theListShape2) const;
346 
347  Standard_EXPORT
348  void UpdateChecked(const TopoDS_Shape& theS1,
349  const Standard_Integer theFlag);
350  //
351  TopoDS_Shape myShapeWhere;
355  TopTools_DataMapOfShapeShape myShapesInclusive;
356  Standard_Real myTolMass;
357  Standard_Real myTolCG;
358  Standard_Boolean myFound;
360  TopTools_DataMapOfShapeInteger myChecked;
361  //
362  TopoDS_Shape myResult;
363 
364 private:
365 };
366 
367 
368 
369 #endif