LevelS C++ support library
3.83
|
#include <rotmatrix.h>
Public Member Functions | |
rotmatrix (double a00, double a01, double a02, double a10, double a11, double a12, double a20, double a21, double a22) | |
rotmatrix (const vec3 &a, const vec3 &b, const vec3 &c) | |
void | SetToIdentity () |
void | SetToZero () |
void | Transpose () |
void | toAxisAngle (vec3 &axis, double &angle) const |
void | Make_Axis_Rotation_Transform (const vec3 &axis, double angle) |
void | Make_CPAC_Euler_Matrix (double alpha, double beta, double gamma) |
void | Extract_CPAC_Euler_Angles (double &alpha, double &beta, double &gamma) const |
vec3 | Transform (const vec3 &vec) const |
void | Transform (const vec3 &vec, vec3 &vec2) const |
Related Functions | |
(Note that these are not member functions.) | |
rotmatrix | operator* (const rotmatrix &a, const rotmatrix &b) |
void | matmult (const rotmatrix &a, const rotmatrix &b, rotmatrix &res) |
void | TransposeTimes (const rotmatrix &a, const rotmatrix &b, rotmatrix &res) |
std::ostream & | operator<< (std::ostream &os, const rotmatrix &mat) |
Class for rotation transforms in 3D space
Definition at line 42 of file rotmatrix.h.
|
inline |
Constructs a rotation matrix from its nine entries
Definition at line 50 of file rotmatrix.h.
Constructs a rotation matrix so that a is the first column, b is the second column and c is the third column.
Definition at line 38 of file rotmatrix.cc.
void rotmatrix::SetToIdentity | ( | ) |
Sets the matrix to the identity matrix.
Definition at line 45 of file rotmatrix.cc.
void rotmatrix::SetToZero | ( | ) |
Sets all matrix elements to zero.
Definition at line 52 of file rotmatrix.cc.
void rotmatrix::Transpose | ( | ) |
Transposes the matrix.
Definition at line 58 of file rotmatrix.cc.
void rotmatrix::toAxisAngle | ( | vec3 & | axis, |
double & | angle | ||
) | const |
Extracts a unit-length rotation axis axis and a rotation angle angle (in radian) from the matrix.
Definition at line 65 of file rotmatrix.cc.
void rotmatrix::Make_Axis_Rotation_Transform | ( | const vec3 & | axis, |
double | angle | ||
) |
Constructs a matrix which causes a rotation by angle radians around axis. axis must have unit length.
Definition at line 117 of file rotmatrix.cc.
void rotmatrix::Make_CPAC_Euler_Matrix | ( | double | alpha, |
double | beta, | ||
double | gamma | ||
) |
Creates a rotation matrix A, which performs the following operations on a vector v, when Av is calculated:
Definition at line 136 of file rotmatrix.cc.
void rotmatrix::Extract_CPAC_Euler_Angles | ( | double & | alpha, |
double & | beta, | ||
double & | gamma | ||
) | const |
Extracts the Euler angles alpha, beta and gamma from the matrix. For their definition see Make_CPAC_Euler_Matrix().
Definition at line 147 of file rotmatrix.cc.
Returns the vector vec, transformed by the matrix.
Definition at line 101 of file rotmatrix.h.
Returns the vector vec, transformed by the matrix, in vec2.
Definition at line 109 of file rotmatrix.h.