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
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
|
-- File: BlendToy_Fillet.cdl
-- Created: Fri Jul 26 11:28:31 1996
-- Authors: Maria PUMBORIOS
-- Laurent BOURESCHE
-- <mps@sgi30>
---Copyright: Matra Datavision 1996
private class InternalBuilder from FilletSurf inherits FilBuilder from ChFi3d
---Purpose: This class is private. It is used by the class Builder
-- from FilletSurf. It computes geometric information about fillets.
uses
SurfData from ChFiDS,
HElSpine from ChFiDS,
Spine from ChFiDS,
SequenceOfSurfData from ChFiDS,
HSurface from BRepAdaptor,
TopolTool from Adaptor3d,
Shape,Edge,Face from TopoDS,
Surface from Geom,
Curve from Geom,
TrimmedCurve from Geom,
FilletShape from ChFi3d,
ListOfShape from TopTools,
Vector from math,
Real from Standard,
Curve from Geom2d,
Pnt from gp,
StatusType,ErrorTypeStatus,StatusDone from FilletSurf,
HCurve2d from BRepAdaptor,
Orientation from TopAbs
is
Create(S : Shape from TopoDS;
FShape : FilletShape from ChFi3d = ChFi3d_Polynomial;
Ta : Real from Standard = 1.0e-2;
Tapp3d : Real from Standard=1.0e-4;
Tapp2d : Real from Standard=1.0e-5)
returns InternalBuilder from FilletSurf;
Add(me : in out;
E : ListOfShape from TopTools;
R : Real from Standard)
---Purpose: Initializes the contour with a list of Edges
-- 0 : no problem
-- 1 : empty list
-- 2 : the edges are not G1
-- 3 : two connected faces on a same support are not G1
-- 4 : the edge is not on shape
-- 5 : NotSharpEdge: the edge is not sharp
returns Integer from Standard;
Perform(me : in out);
--- computation of the fillet
PerformSurf(me : in out;
SeqData : out SequenceOfSurfData from ChFiDS;
Guide : HElSpine from ChFiDS;
Spine : Spine from ChFiDS;
Choix : Integer from Standard;
S1 : HSurface from BRepAdaptor;
I1 : TopolTool from Adaptor3d;
S2 : HSurface from BRepAdaptor;
I2 : TopolTool from Adaptor3d;
MaxStep : Real from Standard;
Fleche : Real from Standard;
TolGuide : Real from Standard;
First,Last : in out Real from Standard;
Inside,Appro : Boolean from Standard;
Forward : Boolean from Standard;
RecOnS1,RecOnS2 : Boolean from Standard;
Soldep : Vector from math;
Intf,Intl : in out Boolean from Standard)
returns Boolean
is redefined protected;
---Purpose: This method calculates the elements of construction of the
-- fillet (constant or evolutive).
--
PerformSurf(me : in out;
SeqData : out SequenceOfSurfData from ChFiDS;
Guide : HElSpine from ChFiDS;
Spine : Spine from ChFiDS;
Choix : Integer from Standard;
S1 : HSurface from BRepAdaptor;
I1 : TopolTool from Adaptor3d;
PC1 : HCurve2d from BRepAdaptor;
Sref1 : HSurface from BRepAdaptor;
PCref1 : HCurve2d from BRepAdaptor;
Decroch1 : out Boolean from Standard;
S2 : HSurface from BRepAdaptor;
I2 : TopolTool from Adaptor3d;
Or2 : Orientation from TopAbs;
MaxStep : Real from Standard;
Fleche : Real from Standard;
TolGuide : Real from Standard;
First,Last : in out Real from Standard;
Inside,Appro,Forward : Boolean from Standard;
RecP,RecS,RecRst : Boolean from Standard;
Soldep : Vector from math)
is redefined protected;
PerformSurf(me : in out;
SeqData : out SequenceOfSurfData from ChFiDS;
Guide : HElSpine from ChFiDS;
Spine : Spine from ChFiDS;
Choix : Integer from Standard;
S1 : HSurface from BRepAdaptor;
I1 : TopolTool from Adaptor3d;
Or1 : Orientation from TopAbs;
S2 : HSurface from BRepAdaptor;
I2 : TopolTool from Adaptor3d;
PC2 : HCurve2d from BRepAdaptor;
Sref2 : HSurface from BRepAdaptor;
PCref2 : HCurve2d from BRepAdaptor;
Decroch2 : out Boolean from Standard;
MaxStep : Real from Standard;
Fleche : Real from Standard;
TolGuide : Real from Standard;
First,Last : in out Real from Standard;
Inside,Appro,Forward : Boolean from Standard;
RecP,RecS,RecRst : Boolean from Standard;
Soldep : Vector from math)
is redefined protected;
PerformSurf(me : in out;
Data : out SequenceOfSurfData from ChFiDS;
Guide : HElSpine from ChFiDS;
Spine : Spine from ChFiDS;
Choix : Integer from Standard;
S1 : HSurface from BRepAdaptor;
I1 : TopolTool from Adaptor3d;
PC1 : HCurve2d from BRepAdaptor;
Sref1 : HSurface from BRepAdaptor;
PCref1 : HCurve2d from BRepAdaptor;
Decroch1 : out Boolean from Standard;
Or1 : Orientation from TopAbs;
S2 : HSurface from BRepAdaptor;
I2 : TopolTool from Adaptor3d;
PC2 : HCurve2d from BRepAdaptor;
Sref2 : HSurface from BRepAdaptor;
PCref2 : HCurve2d from BRepAdaptor;
Decroch2 : out Boolean from Standard;
Or2 : Orientation from TopAbs;
MaxStep : Real from Standard;
Fleche : Real from Standard;
TolGuide : Real from Standard;
First,Last : in out Real from Standard;
Inside,Appro,Forward : Boolean from Standard;
RecP1,RecRst1 : Boolean from Standard;
RecP2,RecRst2 : Boolean from Standard;
Soldep : Vector from math)
is redefined protected;
Done (me) returns Boolean from Standard;
NbSurface(me) returns Integer from Standard;
---Purpose: gives the number of NUBS surfaces of the Fillet.
SurfaceFillet (me;Index:Integer from Standard)
---Purpose: gives the NUBS surface of index Index.
---C++: return const &
returns Surface from Geom;
TolApp3d (me;Index:Integer from Standard) returns Real from Standard;
---Purpose: gives the 3d tolerance reached during approximation
-- of the surface of index Index
SupportFace1 (me;Index:Integer from Standard)
---Purpose:gives the first support face relative to SurfaceFillet(Index);
---C++:return const &
returns Face from TopoDS;
SupportFace2 (me;Index:Integer from Standard)
---Purpose:gives the second support face relative to SurfaceFillet(Index);
---C++:return const &
returns Face from TopoDS;
CurveOnFace1 (me;Index:Integer from Standard)
---C++: return const &
--- Purpose: gives the 3d curve of SurfaceFillet(Index) on SupportFace1(Index)
returns Curve from Geom;
CurveOnFace2 (me;Index:Integer from Standard)
---C++: return const &
---Purpose: gives the 3d curve of SurfaceFillet(Index) on SupportFace2(Index)
returns Curve from Geom;
PCurveOnFace1(me;Index:Integer from Standard)
---Purpose:gives the PCurve associated to CurvOnSup1(Index) on the support face
---C++: return const&
returns Curve from Geom2d;
PCurve1OnFillet (me;Index:Integer from Standard)
---Purpose: gives the PCurve associated to CurveOnFace1(Index) on the Fillet
---C++: return const&
returns Curve from Geom2d;
PCurveOnFace2(me;Index:Integer from Standard)
---Purpose: gives the PCurve associated to CurveOnSup2(Index) on the support face
---C++: return const&
returns Curve from Geom2d;
PCurve2OnFillet (me;Index:Integer from Standard)
---Purpose: gives the PCurve associated to CurveOnSup2(Index) on the fillet
---C++: return const&
returns Curve from Geom2d;
FirstParameter(me)
---Purpose:gives the parameter of the fillet on the first edge.
--
--
--
returns Real from Standard;
LastParameter (me)
---Purpose: gives the parameter of the fillet on the last edge
--
returns Real from Standard;
StartSectionStatus(me)
-- returns:
-- TwoExtremityOnEdge: each extremity of start section of the Fillet is
-- on the edge of the corresponding support face.
-- OneExtremityOnEdge: only one of the extremities of start section of the Fillet
-- is on the edge of the corresponding support face.
-- NoExtremityOnEdge: any extremity of the start section ofthe fillet is on
-- the edge of the corresponding support face.
returns StatusType from FilletSurf;
EndSectionStatus(me)
-- returns:
-- twoExtremityonEdge : each extremity of end section of the Fillet is
-- on the edge of the corresponding support face.
-- OneExtremityOnEdge: only one of the extremities of end section of the Fillet
-- is on the edge of the corresponding support face.
-- NoExtremityOnEdge : any extremity of the end section of the fillet is on
-- the edge of the corresponding support face.
returns StatusType from FilletSurf;
Simulate (me:in out);
-- computes only the sections used in the computation of the fillet
NbSection(me;IndexSurf:Integer from Standard)
returns Integer from Standard;
-- gives the number of sections relative to SurfaceFillet(IndexSurf)
Section(me;IndexSurf:Integer from Standard;IndexSec:Integer from Standard;
Circ: out TrimmedCurve from Geom);
-- gives the arc of circle corresponding to section number
-- IndexSec of SurfaceFillet(IndexSurf) (The basis curve of the
-- trimmed curve is a Geom_Circle)
end InternalBuilder;
|