|
vmath
vmath-0.11
|
Class for matrix 3x3. More...
#include <vmath.h>
Collaboration diagram for Matrix3< T >:Public Member Functions | |
| Matrix3 () | |
| Creates identity matrix. More... | |
| Matrix3 (const T *dt) | |
| Copy matrix values from array (these data must be in column major order!) More... | |
| Matrix3 (const Matrix3< T > &src) | |
| Copy constructor. More... | |
| template<class FromT > | |
| Matrix3 (const Matrix3< FromT > &src) | |
| Copy casting constructor. More... | |
| void | identity () |
| Resets matrix to be identity matrix. More... | |
| bool | operator== (const Matrix3< T > &rhs) const |
| Equality test operator. More... | |
| bool | operator!= (const Matrix3< T > &rhs) const |
| Inequality test operator. More... | |
| T & | at (int x, int y) |
| Get reference to element at position (x,y). More... | |
| const T & | at (int x, int y) const |
| Get constant reference to element at position (x,y). More... | |
| T & | operator() (int i, int j) |
| Get reference to element at position (i,j), with math matrix notation. More... | |
| const T & | operator() (int i, int j) const |
| Get constant reference to element at position (i,j), with math matrix notation. More... | |
| Matrix3< T > & | operator= (const Matrix3< T > &rhs) |
| Copy operator. More... | |
| template<class FromT > | |
| Matrix3< T > & | operator= (const Matrix3< FromT > &rhs) |
| Copy casting operator. More... | |
| Matrix3< T > & | operator= (const T *rhs) |
| Copy operator. More... | |
| Matrix3< T > | operator+ (const Matrix3< T > &rhs) const |
| Addition operator. More... | |
| Matrix3< T > | operator- (const Matrix3< T > &rhs) const |
| Subtraction operator. More... | |
| Matrix3< T > | operator+ (T rhs) const |
| Addition operator. More... | |
| Matrix3< T > | operator- (T rhs) const |
| Subtraction operator. More... | |
| Matrix3< T > | operator* (T rhs) const |
| Multiplication operator. More... | |
| Matrix3< T > | operator/ (T rhs) const |
| Division operator. More... | |
| Vector3< T > | operator* (const Vector3< T > &rhs) const |
| Multiplication operator. More... | |
| Matrix3< T > | operator* (Matrix3< T > rhs) const |
| Multiplication operator. More... | |
| Matrix3< T > | transpose () |
| Transpose matrix. More... | |
| Matrix3< T > | lerp (T fact, const Matrix3< T > &rhs) const |
| Linear interpolation of two matrices. More... | |
| T | det () |
| Matrix3< T > | inverse () |
| Computes inverse matrix. More... | |
| operator T* () | |
| Conversion to pointer operator. More... | |
| operator const T * () const | |
| Conversion to pointer operator. More... | |
| std::string | toString () const |
| Gets string representation. More... | |
Static Public Member Functions | |
| static Matrix3< T > | createRotationAroundAxis (T xDeg, T yDeg, T zDeg) |
| Creates rotation matrix by rotation around axis. More... | |
| template<class It > | |
| static Matrix3< T > | fromOde (const It *mat) |
| Creates rotation matrix from ODE Matrix. More... | |
| template<class FromT > | |
| static Matrix3< T > | fromRowMajorArray (const FromT *arr) |
| Creates new matrix 3x3 from array that represents such matrix 3x3 as array of tightly packed elements in row major order. More... | |
| template<class FromT > | |
| static Matrix3< T > | fromColumnMajorArray (const FromT *arr) |
| Creates new matrix 3x3 from array that represents such matrix 3x3 as array of tightly packed elements in column major order. More... | |
Public Attributes | |
| T | data [9] |
| Data stored in column major order. More... | |
Friends | |
| std::ostream & | operator<< (std::ostream &lhs, const Matrix3< T > &rhs) |
| Output to stream operator. More... | |
Class for matrix 3x3.
Copy matrix values from array (these data must be in column major order!)
Copy constructor.
| src | Data source for new created instance of Matrix3 |
|
inline |
Copy casting constructor.
| src | Data source for new created instance of Matrix3 |
|
inline |
Get reference to element at position (x,y).
| x | Number of column (0..2) |
| y | Number of row (0..2) |
|
inline |
Get constant reference to element at position (x,y).
| x | Number of column (0..2) |
| y | Number of row (0..2) |
|
inlinestatic |
Creates rotation matrix by rotation around axis.
| xDeg | Angle (in degrees) of rotation around axis X. |
| yDeg | Angle (in degrees) of rotation around axis Y. |
| zDeg | Angle (in degrees) of rotation around axis Z. |
|
inline |
|
inlinestatic |
Creates new matrix 3x3 from array that represents such matrix 3x3 as array of tightly packed elements in column major order.
| arr | An array of elements for 3x3 matrix in column major order. |
|
inlinestatic |
Creates rotation matrix from ODE Matrix.
|
inlinestatic |
Creates new matrix 3x3 from array that represents such matrix 3x3 as array of tightly packed elements in row major order.
| arr | An array of elements for 3x3 matrix in row major order. |
|
inline |
Resets matrix to be identity matrix.
Computes inverse matrix.
Linear interpolation of two matrices.
| fact | Factor of interpolation. For translation from positon of this matrix (lhs) to matrix rhs, values of factor goes from 0.0 to 1.0. |
| rhs | Second Matrix for interpolation |
|
inline |
Conversion to pointer operator.
|
inline |
Conversion to pointer operator.
Inequality test operator.
| rhs | Right hand side argument of binary operator. |
|
inline |
Get reference to element at position (i,j), with math matrix notation.
| i | Number of row (1..3) |
| j | Number of column (1..3) |
|
inline |
Get constant reference to element at position (i,j), with math matrix notation.
| i | Number of row (1..3) |
| j | Number of column (1..3) |
Multiplication operator.
| rhs | Right hand side argument of binary operator. |
Multiplication operator.
| rhs | Right hand side argument of binary operator. |
Multiplication operator.
| rhs | Right hand side argument of binary operator. |
Addition operator.
| rhs | Right hand side argument of binary operator. |
Addition operator.
| rhs | Right hand side argument of binary operator. |
Subtraction operator.
| rhs | Right hand side argument of binary operator. |
Subtraction operator.
| rhs | Right hand side argument of binary operator. |
Division operator.
| rhs | Right hand side argument of binary operator. |
Copy operator.
| rhs | Right hand side argument of binary operator. |
|
inline |
Copy casting operator.
| rhs | Right hand side argument of binary operator. |
Copy operator.
| rhs | Right hand side argument of binary operator. |
Equality test operator.
| rhs | Right hand side argument of binary operator. |
|
inline |
Gets string representation.
|
friend |
Output to stream operator.
| lhs | Left hand side argument of operator (commonly ostream instance). |
| rhs | Right hand side argument of operator. |
| T Matrix3< T >::data[9] |
Data stored in column major order.