0024166: Unable to create file with "Save" menu of voxeldemo Qt sample
[occt.git] / src / gp / gp.cdl
1 -- Created on: 1993-04-13
2 -- Created by: JCV
3 -- Copyright (c) 1993-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
21
22
23
24
25
26 package gp 
27
28         --- Purpose :
29         --  The geometric processor package, called gp, provides an 
30         --  implementation of entities used  :
31         --  . for algebraic calculation such as "XYZ" coordinates, "Mat"
32         --    matrix
33         --  . for basis analytic geometry such as Transformations, point,
34         --    vector, line, plane, axis placement, conics, and elementary
35         --    surfaces.
36         --  These entities are defined in 2d and 3d space.
37         --  All the classes of this package are non-persistent.         
38
39 uses Standard, TColStd
40
41 is
42
43   exception VectorWithNullMagnitude inherits DomainError;
44
45   ---Purpose: Identifies the type of a geometric transformation.
46   enumeration TrsfForm is 
47   Identity, Rotation, Translation, PntMirror, Ax1Mirror, Ax2Mirror, Scale, 
48   CompoundTrsf, Other;
49
50   ---Purpose: Enumerates all 24 possible variants of generalized
51   --          Euler angles, defining general 3d rotation by three 
52   --          rotations around main axes of coordinate system,
53   --          in different possible orders. 
54   --          The name of the enumeration
55   --          corresponds to order of rotations, prefixed by type
56   --          of co-ordinate system used:
57   --          - Intrinsic: rotations are made around axes of rotating 
58   --            co-ordinate system associated with the object
59   --          - Extrinsic: rotations are made around axes of fixed 
60   --            (reference) co-ordinate system
61   --          Two specific values provided for most frequently used 
62   --          conventions: proper Euler angles (intrinsic ZXZ) and
63   --          yaw-pitch-roll (intrinsic ZYX).
64   enumeration EulerSequence is
65     EulerAngles,  -- standard Euler angles, alias to Intrinsic_ZXZ
66     YawPitchRoll, -- Yaw Pitch Roll angles, alias to Intrinsic_ZYX
67
68     -- Tait-Bryan angles (using three different axes)
69     Extrinsic_XYZ, 
70     Extrinsic_XZY, 
71     Extrinsic_YZX, 
72     Extrinsic_YXZ, 
73     Extrinsic_ZXY, 
74     Extrinsic_ZYX, 
75
76     Intrinsic_XYZ, 
77     Intrinsic_XZY, 
78     Intrinsic_YZX, 
79     Intrinsic_YXZ, 
80     Intrinsic_ZXY, 
81     Intrinsic_ZYX, 
82
83     -- proper Euler angles (using two different axes, first and third the same)
84     Extrinsic_XYX, 
85     Extrinsic_XZX, 
86     Extrinsic_YZY, 
87     Extrinsic_YXY, 
88     Extrinsic_ZYZ, 
89     Extrinsic_ZXZ,
90
91     Intrinsic_XYX, 
92     Intrinsic_XZX, 
93     Intrinsic_YZY, 
94     Intrinsic_YXY, 
95     Intrinsic_ZXZ,
96     Intrinsic_ZYZ 
97   ;
98
99   class XYZ;
100         --- Purpose : 3D Cartesian Coordinates {X, Y, Z}
101
102   class Mat;
103         --- Purpose : Matrix 3*3
104
105   class Quaternion;
106         --- Purpose : Quaternion representing 3d rotation
107
108   class Trsf;
109         --- Purpose :
110         --  Elementary geometric transformation. This transformation never 
111         --  change the nature of the objects.
112
113   class GTrsf;
114         --- Purpose :
115         --  General transformation. A GTrsf can be used only to transform
116         --  a point or a triplet of coordinates.
117
118   class Pnt;
119         --- Purpose : Cartesian Point.
120
121   class Vec;
122         --- Purpose : Vector.
123
124   class Dir;
125         --- Purpose : Direction, it is an unitary vector.
126
127   class Ax1;
128         --- Purpose : axis placement (Coordinate system -one axis)
129
130   class Ax2;
131         --- Purpose :  axis  placement (Direct  Coordinate  system two
132         --  axis)
133
134   class Ax3;
135         --- Purpose : axis placement  (Coordinate system two axis, can
136         --  be direct  or indirect)
137
138   class Lin;
139         --- Purpose : Line.
140
141   class Circ;
142         --- Purpose : Circle.
143
144   class Elips;
145         --- Purpose : Ellipse.
146
147   class Hypr;
148         --- Purpose : Hyperbola.
149   
150   class Parab;
151         --- Purpose : Parabola.
152   
153   class Pln;
154         --- Purpose : Plane.
155
156   class Cylinder;
157         --- Purpose : Infinite cylindrical surface  .
158   
159   class Sphere;
160         --- Purpose : Spherical surface.  
161   
162   class Torus;
163         --- Purpose : Toroidal surface.  
164   
165   class Cone;
166         --- Purpose : Conical surface.
167
168
169
170
171         --- Purpose : Geometric entities for 2D.
172
173
174
175   class XY;
176         --- Purpose : 2D cartesian Coordinates {X, Y}
177
178   class Mat2d;
179         --- Purpose : Matrix 2*2
180
181   class Trsf2d;
182         --- Purpose :
183         --  Elementary geometric transformation. This transformation never 
184         --  change the nature of the objects.
185
186   class GTrsf2d;
187         --- Purpose :
188         --  General transformation. A GTrsf can be used only to transform
189         --  a point or a triplet of coordinates.
190
191   class Pnt2d;
192         --- Purpose : Cartesian point.
193
194   class Vec2d;
195         --- Purpose : Vector.
196
197   class Dir2d;
198         --- Purpose : Direction, it is an unitary vector.
199
200   class Ax2d;
201         --- Purpose : axis placement (Coordinate system - one axis)
202
203   class Ax22d;
204         --- Purpose : axis placement (Coordinate system - two axis)
205
206   class Lin2d;
207         --- Purpose : Line.
208
209   class Circ2d;
210         --- Purpose : Circle.
211
212   class Elips2d;
213         --- Purpose : Ellipse.
214
215   class Hypr2d;
216         --- Purpose : Hyperbola.
217
218   class Parab2d;
219         --- Purpose : Parabola.
220   
221
222
223         --- Purpose : Method of package gp 
224
225    Resolution  returns Real;
226         --- Purpose :
227         --  In geometric computations, defines the tolerance criterion
228         -- used to determine when two numbers can be considered equal.
229         -- Many class functions use this tolerance criterion, for
230         -- example, to avoid division by zero in geometric
231         -- computations. In the documentation, tolerance criterion is
232         -- always referred to as gp::Resolution().
233         ---C++: inline
234
235
236   Origin returns Pnt from gp;
237      --- Purpose : Identifies a Cartesian point with coordinates X = Y = Z = 0.0.0
238      ---C++: return const &
239
240   DX returns Dir from gp;
241      ---Purpose: Returns a unit vector with the combination (1,0,0)
242      ---C++: return const &
243         
244   DY returns Dir from gp;
245      ---Purpose: Returns a unit vector with the combination (0,1,0)
246      ---C++: return const &
247         
248   DZ returns Dir from gp;
249      ---Purpose: Returns a unit vector with the combination (0,0,1)
250      ---C++: return const &
251         
252   OX returns Ax1 from gp;
253      --- Purpose :Identifies an axis where its origin is Origin 
254      -- and its unit vector coordinates  X = 1.0,  Y = Z = 0.0
255      ---C++: return const &
256
257   OY returns Ax1 from gp;
258      --- Purpose :Identifies an axis where its origin is Origin 
259      -- and its unit vector coordinates Y = 1.0,  X = Z = 0.0
260      ---C++: return const &
261
262   OZ returns Ax1 from gp;
263      --- Purpose :Identifies an axis where its origin is Origin 
264      -- and its unit vector coordinates Z = 1.0,  Y = X = 0.0
265      ---C++: return const &
266
267
268   XOY returns Ax2 from gp;
269      --- Purpose :Identifies a coordinate system where its origin is Origin,
270      -- and its "main Direction" and "X Direction" coordinates
271      --  Z = 1.0, X = Y =0.0 and X direction coordinates X = 1.0, Y = Z = 0.0
272      ---C++: return const &
273
274   ZOX returns Ax2 from gp;
275      --- Purpose :Identifies a coordinate system where its origin is Origin,
276      -- and its "main Direction" and "X Direction" coordinates
277      --  Y = 1.0, X = Z =0.0 and X direction coordinates Z = 1.0, X = Y = 0.0
278      ---C++: return const &
279     
280   YOZ returns Ax2 from gp;
281      --- Purpose :Identifies a coordinate system where its origin is Origin,
282      -- and its "main Direction" and "X Direction" coordinates
283      --  X = 1.0, Z = Y =0.0 and X direction coordinates Y = 1.0, X = Z = 0.0
284      ---C++: return const &
285
286
287
288      --- Purpose : In 2D space 
289
290   Origin2d returns Pnt2d from gp;
291      --- Purpose : Identifies a Cartesian point with coordinates X = Y = 0.0
292      ---C++: return const &
293   
294   DX2d returns Dir2d from gp;
295      ---Purpose: Returns a unit vector with the combinations (1,0)
296      ---C++: return const &
297   
298   DY2d returns Dir2d from gp;
299      ---Purpose: Returns a unit vector with the combinations (0,1)
300      ---C++: return const &
301   
302   OX2d returns Ax2d from gp;
303      --- Purpose : Identifies an axis where its origin is Origin2d
304      -- and its unit vector coordinates are: X = 1.0,  Y = 0.0
305      ---C++: return const &
306
307   OY2d returns Ax2d from gp;
308      --- Purpose :  Identifies an axis where its origin is Origin2d
309      -- and its unit vector coordinates are Y = 1.0,  X = 0.0
310      ---C++: return const &
311
312 end gp;
313
314