Adding of testing cases from subgroups 937 940 and 941 of CHL group
[occt.git] / src / BRepFeat / BRepFeat.cdl
CommitLineData
b311480e 1-- Created on: 1995-06-13
2-- Created by: Jacques GOUSSARD
3-- Copyright (c) 1995-1999 Matra Datavision
4-- Copyright (c) 1999-2012 OPEN CASCADE SAS
5--
6-- The content of this file is subject to the Open CASCADE Technology Public
7-- License Version 6.5 (the "License"). You may not use the content of this file
8-- except in compliance with the License. Please obtain a copy of the License
9-- at http://www.opencascade.org and read it completely before using this file.
10--
11-- The Initial Developer of the Original Code is Open CASCADE S.A.S., having its
12-- main offices at: 1, place des Freres Montgolfier, 78280 Guyancourt, France.
13--
14-- The Original Code and all software distributed under the License is
15-- distributed on an "AS IS" basis, without warranty of any kind, and the
16-- Initial Developer hereby disclaims all such warranties, including without
17-- limitation, any warranties of merchantability, fitness for a particular
18-- purpose or non-infringement. Please see the License for the specific terms
19-- and conditions governing the rights and limitations under the License.
20
7fd59977 21
22
23package BRepFeat
24
25 ---Purpose: BRepFeat is necessary for the
26 -- creation and manipulation of both form and mechanical features in a
27 -- Boundary Representation framework. Form features can be depressions or
28 -- protrusions and include the following types:
29 -- - Cylinder
30 -- - Draft Prism
31 -- - Prism
32 -- - Revolved feature
33 -- - Pipe
34 -- Depending on whether you wish to make a depression or a protrusion,
35 -- you can choose your operation type between the following:
36 -- - removing matter (a Boolean cut: Fuse setting 0)
37 -- - adding matter (Boolean fusion: Fuse setting 1)
38 -- The semantics of form feature creation is based on the
39 -- construction of shapes:
40 -- - for a certain length in a certain direction
41 -- - up to a limiting face
42 -- - from a limiting face at a height
43 -- - above and/or below a plane
44 -- The shape defining the construction of a feature can be either a
45 -- supporting edge or a concerned area of a face.
46 -- In case of supporting edge, this contour can be attached to a face
47 -- of the basis shape by binding. When the contour is bound to this face,
48 -- the information that the contour will slide on the face becomes
49 -- available to the relevant class methods. In case of the concerned
50 -- area of a face, you could, for example, cut it out and move it at
51 -- a different height, which will define the limiting face of a
52 -- protrusion or depression. Topological definition with local
53 -- operations of this sort makes calculations simpler and faster
54 -- than a global operation. The latter would entail a second phase of
55 -- removing unwanted matter to get the same result.
56 -- Mechanical features include ribs - protrusions - and grooves (or
57 -- slots) - depressions along planar (linear) surfaces or revolution surfaces.
58 -- The semantics of mechanical features is based on giving
59 -- thickness to a contour. This thickness can either be unilateral
60 -- - on one side of the contour - or bilateral - on both sides. As in
61 -- the semantics of form features, the thickness is defined by
62 -- construction of shapes in specific contexts.
63 -- However, in case of mechanical features, development contexts
64 -- differ. Here they include extrusion:
65 -- - to a limiting face of the basis shape
66 -- - to or from a limiting plane
67 -- - to a height.
68
69uses BRepBuilderAPI,
70 LocOpe,
71 TopoDS,
72 TopTools,
73 TopOpeBRepBuild,
74 Geom,
75 gp,
76 TColgp,
77 TColGeom,
78 StdFail,
79 BRepTopAdaptor,
80 Geom2dAdaptor,
81 TopAbs,
82 --modified by NIZNHY-PKV Thu Mar 21 18:31:59 2002 f
83 BRepAlgoAPI,
84 --modified by NIZNHY-PKV Thu Mar 21 18:32:02 2002 t
85 BOP
86
87is
88
89 enumeration StatusError is
90 ---Purpose: Discribes the error.
91 OK,
92 BadDirect,
93 BadIntersect,
94 EmptyBaryCurve,
95 EmptyCutResult,
96 FalseSide,
97 IncDirection,
98 IncSlidFace,
99 IncParameter,
100 IncTypes,
101 IntervalOverlap,
102 InvFirstShape,
103 InvOption,
104 InvShape,
105 LocOpeNotDone,
106 LocOpeInvNotDone,
107 NoExtFace,
108 NoFaceProf,
109 NoGluer,
110 NoIntersectF,
111 NoIntersectU,
112 NoParts,
113 NoProjPt,
114 NotInitialized,
115 NotYetImplemented,
116 NullRealTool,
117 NullToolF,
118 NullToolU
119
120 end StatusError;
121
122
123 deferred class Builder; -- inherits MakeShape from BRepBuilderAPI
124
125 class LocalOperation; -- inherits Builder from BRepFeat;
126
127 class MakeCylindricalHole; -- inherits Builder from BRepFeat;
128
129
130 class SplitShape; -- inherits MakeShape from BRepBuilderAPI;
131
132 deferred class Form; -- inherits MakeShape from BRepBuilderAPI;
133
134 deferred class RibSlot; -- inherits MakeShape from BRepBuilderAPI;
135
136 class MakePrism; -- inherits Form from BRepFeat
137
138 class MakeRevol; -- inherits Form from BRepFeat
139
140 class MakePipe; -- inherits Form from BRepFeat
141
142 class Gluer; -- inherits MakeShape from BRepBuilderAPI
143
144 class MakeDPrism;
145
146 class MakeLinearForm;
147
148 class MakeRevolutionForm;
149
150 enumeration Status is -- to be completed
151
152 NoError,
153 InvalidPlacement,
154 HoleTooLong
155
156 end Status;
157
158 enumeration PerfSelection is
159
160 NoSelection,
161 SelectionFU,
162 SelectionU,
163 SelectionSh,
164 SelectionShU
165 ---Purpose: To declare the type of selection semantics for local operation Perform methods
166 -- - NoSelection
167 -- - SelectionFU - selection of a face up to which a
168 -- local operation will be performed
169 -- - SelectionU - selection of a point up to which a
170 -- local operation will be performed
171 -- - SelectionSh - selection of a shape on which a
172 -- local operation will be performed
173 -- - SelectionShU - selection of a shape up to which a
174 -- local operation will be performed.
175 end PerfSelection;
176
177
178 SampleEdges(S : Shape from TopoDS;
179 Pt: in out SequenceOfPnt from TColgp);
180
181
182
183 Barycenter(S : Shape from TopoDS;
184 Pt: in out Pnt from gp);
185
186 ParametricBarycenter(S : Shape from TopoDS;
187 C : Curve from Geom)
188
189 returns Real from Standard;
190
191 ParametricMinMax(S : Shape from TopoDS;
192 C : Curve from Geom;
193 prmin : out Real from Standard;
194 prmax : out Real from Standard;
195 prbmin: out Real from Standard;
196 prbmax: out Real from Standard;
197 flag : out Boolean from Standard;
198 Ori : Boolean from Standard = Standard_False);
199 ---Purpose: Ori = True taking account the orientation
200
201 IsInside(F1 : Face from TopoDS;
202 F2 : Face from TopoDS)
203
204 returns Boolean from Standard;
205
206 IsInOut (FC : FClass2d from BRepTopAdaptor;
207 AC : Curve from Geom2dAdaptor)
208
209
210 returns Boolean from Standard;
211
212 -- TangSli(E : Edge from TopoDS;
213 -- F : Shape from TopoDS)
214
215 -- returns Boolean from Standard;
216
217
218 FaceUntil (S : Shape from TopoDS;
219 F : in out Face from TopoDS);
220
221
222 Tool (SRef : Shape from TopoDS;
223 Fac : Face from TopoDS;
224 Orf : Orientation from TopAbs)
225
226 returns Solid from TopoDS;
227
228 Print(SE : StatusError from BRepFeat; S : in out OStream) returns OStream;
229 ---Purpose: Prints the Error description of the State <St> as a String on
230 -- the Stream <S> and returns <S>.
231 --
232 ---C++: return &
233
234end BRepFeat;