42cf5bc1 |
1 | // Created on: 1993-01-09 |
2 | // Created by: CKY / Contract Toubro-Larsen ( SIVA ) |
3 | // Copyright (c) 1993-1999 Matra Datavision |
4 | // Copyright (c) 1999-2014 OPEN CASCADE SAS |
5 | // |
6 | // This file is part of Open CASCADE Technology software library. |
7 | // |
8 | // This library is free software; you can redistribute it and/or modify it under |
9 | // the terms of the GNU Lesser General Public License version 2.1 as published |
10 | // by the Free Software Foundation, with special exception defined in the file |
11 | // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT |
12 | // distribution for complete text of the license and disclaimer of any warranty. |
13 | // |
14 | // Alternatively, this file may be used under the terms of Open CASCADE |
15 | // commercial license or contractual agreement. |
16 | |
17 | #ifndef _IGESSolid_Ellipsoid_HeaderFile |
18 | #define _IGESSolid_Ellipsoid_HeaderFile |
19 | |
20 | #include <Standard.hxx> |
21 | #include <Standard_Type.hxx> |
22 | |
23 | #include <gp_XYZ.hxx> |
24 | #include <IGESData_IGESEntity.hxx> |
25 | #include <Standard_Real.hxx> |
26 | class gp_XYZ; |
27 | class gp_Pnt; |
28 | class gp_Dir; |
29 | |
30 | |
31 | class IGESSolid_Ellipsoid; |
32 | DEFINE_STANDARD_HANDLE(IGESSolid_Ellipsoid, IGESData_IGESEntity) |
33 | |
34 | //! defines Ellipsoid, Type <168> Form Number <0> |
35 | //! in package IGESSolid |
36 | //! The ellipsoid is a solid bounded by the surface defined |
37 | //! by: |
38 | //! X^2 Y^2 Z^2 |
39 | //! ----- + ----- + ----- = 1 |
40 | //! LX^2 LY^2 LZ^2 |
41 | class IGESSolid_Ellipsoid : public IGESData_IGESEntity |
42 | { |
43 | |
44 | public: |
45 | |
46 | |
47 | Standard_EXPORT IGESSolid_Ellipsoid(); |
48 | |
49 | //! This method is used to set the fields of the class |
50 | //! Ellipsoid |
51 | //! - aSize : Lengths in the local X,Y,Z directions |
52 | //! - aCenter : Center point of ellipsoid (default (0,0,0)) |
53 | //! - anXAxis : Unit vector defining local X-axis |
54 | //! default (1,0,0) |
55 | //! - anZAxis : Unit vector defining local Z-axis |
56 | //! default (0,0,1) |
57 | Standard_EXPORT void Init (const gp_XYZ& aSize, const gp_XYZ& aCenter, const gp_XYZ& anXAxis, const gp_XYZ& anZAxis); |
58 | |
59 | //! returns the size |
60 | Standard_EXPORT gp_XYZ Size() const; |
61 | |
62 | //! returns the length in the local X-direction |
63 | Standard_EXPORT Standard_Real XLength() const; |
64 | |
65 | //! returns the length in the local Y-direction |
66 | Standard_EXPORT Standard_Real YLength() const; |
67 | |
68 | //! returns the length in the local Z-direction |
69 | Standard_EXPORT Standard_Real ZLength() const; |
70 | |
71 | //! returns the center of the ellipsoid |
72 | Standard_EXPORT gp_Pnt Center() const; |
73 | |
74 | //! returns the center of the ellipsoid after applying |
75 | //! TransformationMatrix |
76 | Standard_EXPORT gp_Pnt TransformedCenter() const; |
77 | |
78 | //! returns the vector corresponding to the local X-direction |
79 | Standard_EXPORT gp_Dir XAxis() const; |
80 | |
81 | //! returns the vector corresponding to the local X-direction |
82 | //! after applying TransformationMatrix |
83 | Standard_EXPORT gp_Dir TransformedXAxis() const; |
84 | |
85 | //! returns the vector corresponding to the local Y-direction |
86 | //! which is got by taking cross product of ZAxis and XAxis |
87 | Standard_EXPORT gp_Dir YAxis() const; |
88 | |
89 | //! returns the vector corresponding to the local Y-direction |
90 | //! (which is got by taking cross product of ZAxis and XAxis) |
91 | //! after applying TransformationMatrix |
92 | Standard_EXPORT gp_Dir TransformedYAxis() const; |
93 | |
94 | //! returns the vector corresponding to the local Z-direction |
95 | Standard_EXPORT gp_Dir ZAxis() const; |
96 | |
97 | //! returns the vector corresponding to the local Z-direction |
98 | //! after applying TransformationMatrix |
99 | Standard_EXPORT gp_Dir TransformedZAxis() const; |
100 | |
101 | |
102 | |
103 | |
92efcf78 |
104 | DEFINE_STANDARD_RTTIEXT(IGESSolid_Ellipsoid,IGESData_IGESEntity) |
42cf5bc1 |
105 | |
106 | protected: |
107 | |
108 | |
109 | |
110 | |
111 | private: |
112 | |
113 | |
114 | gp_XYZ theSize; |
115 | gp_XYZ theCenter; |
116 | gp_XYZ theXAxis; |
117 | gp_XYZ theZAxis; |
118 | |
119 | |
120 | }; |
121 | |
122 | |
123 | |
124 | |
125 | |
126 | |
127 | |
128 | #endif // _IGESSolid_Ellipsoid_HeaderFile |