Data structure for Euler angles in three dimensions.
More...
#include <JEulerAngle3D.hh>
Data structure for Euler angles in three dimensions.
This class implements the JMATH::JMath interface.
Definition at line 36 of file JEulerAngle3D.hh.
◆ JEulerAngle3D() [1/4]
JGEOMETRY3D::JEulerAngle3D::JEulerAngle3D |
( |
| ) |
|
|
inline |
◆ JEulerAngle3D() [2/4]
JGEOMETRY3D::JEulerAngle3D::JEulerAngle3D |
( |
const double | alpha, |
|
|
const double | beta, |
|
|
const double | gamma ) |
|
inline |
Constructor.
- Parameters
-
alpha | alpha angle [rad] |
beta | beta angle [rad] |
gamma | gamma angle [rad] |
Definition at line 57 of file JEulerAngle3D.hh.
◆ JEulerAngle3D() [3/4]
JGEOMETRY3D::JEulerAngle3D::JEulerAngle3D |
( |
const JAngle3D & | angle | ) |
|
|
inline |
◆ JEulerAngle3D() [4/4]
JGEOMETRY3D::JEulerAngle3D::JEulerAngle3D |
( |
const JVersor3D & | versor | ) |
|
|
inline |
◆ getEulerAngle()
const JEulerAngle3D & JGEOMETRY3D::JEulerAngle3D::getEulerAngle |
( |
| ) |
const |
|
inline |
Get Euler angle.
- Returns
- this angle
Definition at line 95 of file JEulerAngle3D.hh.
96 {
98 }
JEulerAngle3D()
Default constructor.
◆ setEulerAngle()
void JGEOMETRY3D::JEulerAngle3D::setEulerAngle |
( |
const JEulerAngle3D & | angle | ) |
|
|
inline |
◆ negate()
Negate angle.
- Returns
- this angle
Definition at line 117 of file JEulerAngle3D.hh.
118 {
122
123 return *this;
124 }
◆ add()
Add angle.
- Parameters
-
- Returns
- this angle
Definition at line 133 of file JEulerAngle3D.hh.
134 {
136 __beta += angle.getBeta();
138
139 return *this;
140 }
◆ sub()
Subtract angle.
- Parameters
-
- Returns
- this angle
Definition at line 149 of file JEulerAngle3D.hh.
150 {
152 __beta -= angle.getBeta();
154
155 return *this;
156 }
◆ mul() [1/2]
JEulerAngle3D & JGEOMETRY3D::JEulerAngle3D::mul |
( |
const double | factor | ) |
|
|
inline |
Scale angle.
- Parameters
-
factor | multiplication factor |
- Returns
- this angle
Definition at line 165 of file JEulerAngle3D.hh.
166 {
170
171 return *this;
172 }
◆ div()
JEulerAngle3D & JGEOMETRY3D::JEulerAngle3D::div |
( |
const double | factor | ) |
|
|
inline |
Scale angle.
- Parameters
-
- Returns
- this angle
Definition at line 181 of file JEulerAngle3D.hh.
182 {
186
187 return *this;
188 }
◆ getAlpha()
double JGEOMETRY3D::JEulerAngle3D::getAlpha |
( |
| ) |
const |
|
inline |
◆ getBeta()
double JGEOMETRY3D::JEulerAngle3D::getBeta |
( |
| ) |
const |
|
inline |
◆ getGamma()
double JGEOMETRY3D::JEulerAngle3D::getGamma |
( |
| ) |
const |
|
inline |
◆ mul() [2/2]
template<class JFirst_t , class JSecond_t >
JFirst_t & JMATH::JMath< JFirst_t, JSecond_t >::mul |
( |
const JSecond_t & | object | ) |
|
|
inlineinherited |
Multiply with object.
- Parameters
-
- Returns
- result object
Definition at line 354 of file JMath.hh.
355 {
356 return static_cast<JFirst_t&>(*this) = JFirst_t().mul(static_cast<const JFirst_t&>(*this), object);
357 }
◆ operator>> [1/2]
std::istream & operator>> |
( |
std::istream & | in, |
|
|
JEulerAngle3D & | angle ) |
|
friend |
Read Euler angles from input.
- Parameters
-
in | input stream |
angle | Euler angles |
- Returns
- input stream
Definition at line 231 of file JEulerAngle3D.hh.
232 {
233 in >> angle.__alpha >> angle.__beta >> angle.__gamma;
234
235 return in;
236 }
◆ operator<< [1/2]
std::ostream & operator<< |
( |
std::ostream & | out, |
|
|
const JEulerAngle3D & | angle ) |
|
friend |
Write Euler angles to output.
- Parameters
-
out | output stream |
angle | Euler angle |
- Returns
- output stream
Definition at line 246 of file JEulerAngle3D.hh.
247 {
249
250 out << format << angle.getAlpha() << ' '
251 << format << angle.getBeta() << ' '
252 << format << angle.getGamma();
253
254 return out;
255 }
JFormat_t & getFormat()
Get format for given type.
◆ operator>> [2/2]
Read Euler angles from input.
- Parameters
-
in | reader |
angle | Euler angles |
- Returns
- reader
Definition at line 265 of file JEulerAngle3D.hh.
266 {
267 in >> angle.__alpha;
268 in >> angle.__beta;
269 in >> angle.__gamma;
270
271 return in;
272 }
◆ operator<< [2/2]
Write Euler angles to output.
- Parameters
-
out | writer |
angle | Euler angles |
- Returns
- writer
Definition at line 282 of file JEulerAngle3D.hh.
283 {
284 out << angle.__alpha;
285 out << angle.__beta;
286 out << angle.__gamma;
287
288 return out;
289 }
◆ __alpha
double JGEOMETRY3D::JEulerAngle3D::__alpha |
|
protected |
◆ __beta
double JGEOMETRY3D::JEulerAngle3D::__beta |
|
protected |
◆ __gamma
double JGEOMETRY3D::JEulerAngle3D::__gamma |
|
protected |
The documentation for this class was generated from the following file: