File: BRepOffset_MakeOffset.hxx

package info (click to toggle)
oce 0.18.3-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 301,548 kB
  • sloc: cpp: 1,190,609; ansic: 67,225; sh: 11,630; tcl: 7,954; cs: 5,221; python: 2,867; java: 1,522; makefile: 342; xml: 292; perl: 37
file content (179 lines) | stat: -rw-r--r-- 5,782 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
// This file is generated by WOK (CPPExt).
// Please do not edit this file; modify original file instead.
// The copyright and license terms as defined for the original file apply to 
// this header file considered to be the "object code" form of the original source.

#ifndef _BRepOffset_MakeOffset_HeaderFile
#define _BRepOffset_MakeOffset_HeaderFile

#include <Standard.hxx>
#include <Standard_DefineAlloc.hxx>
#include <Standard_Macro.hxx>

#include <Standard_Real.hxx>
#include <TopoDS_Shape.hxx>
#include <BRepOffset_Mode.hxx>
#include <Standard_Boolean.hxx>
#include <GeomAbs_JoinType.hxx>
#include <TopTools_DataMapOfShapeReal.hxx>
#include <TopTools_IndexedMapOfShape.hxx>
#include <BRepOffset_Analyse.hxx>
#include <BRepAlgo_Image.hxx>
#include <TopTools_ListOfShape.hxx>
#include <Handle_BRepAlgo_AsDes.hxx>
#include <BRepOffset_Error.hxx>
#include <BRepOffset_MakeLoops.hxx>
class BRepAlgo_AsDes;
class TopoDS_Shape;
class TopoDS_Face;
class BRepOffset_Analyse;
class BRepAlgo_Image;
class TopTools_IndexedMapOfShape;
class TopTools_MapOfShape;
class BRepOffset_Inter3d;
class BRepOffset_DataMapOfShapeOffset;



class BRepOffset_MakeOffset 
{
public:

  DEFINE_STANDARD_ALLOC

  
  Standard_EXPORT BRepOffset_MakeOffset();
  
  Standard_EXPORT BRepOffset_MakeOffset(const TopoDS_Shape& S, const Standard_Real Offset, const Standard_Real Tol, const BRepOffset_Mode Mode = BRepOffset_Skin, const Standard_Boolean Intersection = Standard_False, const Standard_Boolean SelfInter = Standard_False, const GeomAbs_JoinType Join = GeomAbs_Arc, const Standard_Boolean Thickening = Standard_False);
  
  Standard_EXPORT   void Initialize (const TopoDS_Shape& S, const Standard_Real Offset, const Standard_Real Tol, const BRepOffset_Mode Mode = BRepOffset_Skin, const Standard_Boolean Intersection = Standard_False, const Standard_Boolean SelfInter = Standard_False, const GeomAbs_JoinType Join = GeomAbs_Arc, const Standard_Boolean Thickening = Standard_False) ;
  
  Standard_EXPORT   void Clear() ;
  
  //! Add Closing Faces,  <F>  has to be  in  the initial
  //! shape S.
  Standard_EXPORT   void AddFace (const TopoDS_Face& F) ;
  
  //! set the offset <Off> on the Face <F>
  Standard_EXPORT   void SetOffsetOnFace (const TopoDS_Face& F, const Standard_Real Off) ;
  
  Standard_EXPORT   void MakeOffsetShape() ;
  
  Standard_EXPORT   void MakeThickSolid() ;
  
  Standard_EXPORT  const  BRepOffset_Analyse& GetAnalyse()  const;
  
  Standard_EXPORT   Standard_Boolean IsDone()  const;
  
  Standard_EXPORT  const  TopoDS_Shape& Shape()  const;
  
  //! returns information if IsDone() = FALSE.
  Standard_EXPORT   BRepOffset_Error Error()  const;
  
  //! Returns <Image> containing links between initials
  //! shapes and offset faces.
  Standard_EXPORT  const  BRepAlgo_Image& OffsetFacesFromShapes()  const;
  
  //! Returns myJoin.
  Standard_EXPORT   GeomAbs_JoinType GetJoinType()  const;
  
  //! Returns <Image> containing links between initials
  //! shapes and offset edges.
  Standard_EXPORT  const  BRepAlgo_Image& OffsetEdgesFromShapes()  const;
  
  //! Returns the list of closing faces stores by AddFace
  Standard_EXPORT  const  TopTools_IndexedMapOfShape& ClosingFaces()  const;
  
  //! Makes pre analysis of possibility offset perform. Use method Error() to get more information.
  //! Finds first error. List of checks:
  //! 1) Check for existence object with non-null offset.
  //! 2) Check for connectivity in offset shell.
  //! 3) Check continuity of input surfaces.
  //! 4) Check for normals existence on grid.
  //! @return 1 if possible make computations and 0 if not possible.
  Standard_EXPORT   Standard_Boolean CheckInputData() ;
  
  //! Return bad shape, which obtained in CheckInputData.
  Standard_EXPORT  const  TopoDS_Shape& GetBadShape()  const;




protected:





private:

  
  Standard_EXPORT   void BuildOffsetByArc() ;
  
  Standard_EXPORT   void BuildOffsetByInter() ;
  
  Standard_EXPORT   void SelfInter (TopTools_MapOfShape& Modif) ;
  
  Standard_EXPORT   void Intersection3D (BRepOffset_Inter3d& Inter) ;
  
  Standard_EXPORT   void Intersection2D (const TopTools_IndexedMapOfShape& Modif, const TopTools_IndexedMapOfShape& NewEdges) ;
  
  Standard_EXPORT   void MakeLoops (TopTools_IndexedMapOfShape& Modif) ;
  
  Standard_EXPORT   void MakeLoopsOnContext (TopTools_MapOfShape& Modif) ;
  
  Standard_EXPORT   void MakeFaces (TopTools_IndexedMapOfShape& Modif) ;
  
  Standard_EXPORT   void MakeShells() ;
  
  Standard_EXPORT   void SelectShells() ;
  
  Standard_EXPORT   void EncodeRegularity() ;
  
  Standard_EXPORT   void MakeSolid() ;
  
  Standard_EXPORT   void ToContext (BRepOffset_DataMapOfShapeOffset& MapSF) ;
  
  //! Private method use to update the map face<->offset
  Standard_EXPORT   void UpdateFaceOffset() ;
  
  //! Private method used to correct degenerated edges on conical faces
  Standard_EXPORT   void CorrectConicalFaces() ;
  
  //! Private method used to build walls for thickening the shell
  Standard_EXPORT   void MakeMissingWalls() ;


  Standard_Real myOffset;
  Standard_Real myTol;
  TopoDS_Shape myShape;
  BRepOffset_Mode myMode;
  Standard_Boolean myInter;
  Standard_Boolean mySelfInter;
  GeomAbs_JoinType myJoin;
  Standard_Boolean myThickening;
  TopTools_DataMapOfShapeReal myFaceOffset;
  TopTools_IndexedMapOfShape myFaces;
  BRepOffset_Analyse myAnalyse;
  TopoDS_Shape myOffsetShape;
  BRepAlgo_Image myInitOffsetFace;
  BRepAlgo_Image myInitOffsetEdge;
  BRepAlgo_Image myImageOffset;
  TopTools_ListOfShape myWalls;
  Handle(BRepAlgo_AsDes) myAsDes;
  Standard_Boolean myDone;
  BRepOffset_Error myError;
  BRepOffset_MakeLoops myMakeLoops;
  TopoDS_Shape myBadShape;
  Standard_Boolean myIsPerformSewing;


};







#endif // _BRepOffset_MakeOffset_HeaderFile