TMatrix Class Reference
basic 4x4 Matrix class (row-major order OpenGL matrix)
More...
#include <mat.h>
List of all members.
Public Member Functions |
| TMatrix () |
| Basic constructor, initialize all values to 0.0.
|
| TMatrix (float v0, float v1, float v2, float v3, float v4, float v5, float v6, float v7, float v8, float v9, float v10, float v11, float v12, float v13, float v14, float v15) |
| Construct matrix directly from 16 float values.
|
| TMatrix (const TMatrix &ref) |
| Copy constructor, initialize values from other TMatrix.
|
void | GetRow (int position, float *ref) const |
| Get one row from matrix.
|
TMatrix | Inverse () |
| returns inverse matrix from current
|
TMatrix | Transpose () |
| returns transposed matrix from current
|
void | LoadIdentity () |
| create identity matrix
|
TMatrix | operator* (const TMatrix &ref) const |
| Multiply current matrix with other through operator *.
|
float * | operator[] (int index) |
| reference operator
|
| operator float * () const |
| retype operator, converts values to float array
|
| operator const float * () const |
| retype operator, converts values to constant float array
|
Friends |
ostream & | operator<< (ostream &os, const TMatrix &m) |
| Print out matrix values as std::ostream object.
|
Detailed Description
basic 4x4 Matrix class (row-major order OpenGL matrix)
Constructor & Destructor Documentation
TMatrix::TMatrix |
( |
float |
v0, |
|
|
float |
v1, |
|
|
float |
v2, |
|
|
float |
v3, |
|
|
float |
v4, |
|
|
float |
v5, |
|
|
float |
v6, |
|
|
float |
v7, |
|
|
float |
v8, |
|
|
float |
v9, |
|
|
float |
v10, |
|
|
float |
v11, |
|
|
float |
v12, |
|
|
float |
v13, |
|
|
float |
v14, |
|
|
float |
v15 | |
|
) |
| | |
Construct matrix directly from 16 float values.
- Parameters:
-
| v0,v1,v2,v3,v4,v5,v6,v7,v8,v9,v10,v11,v12,v13,v14,v15 | float values |
TMatrix::TMatrix |
( |
const TMatrix & |
ref |
) |
|
Copy constructor, initialize values from other TMatrix.
- Parameters:
-
| ref | reference matrix to copy from |
Member Function Documentation
void TMatrix::GetRow |
( |
int |
position, |
|
|
float * |
ref | |
|
) |
| | const |
Get one row from matrix.
- Parameters:
-
[in] | position | row position in the matrix |
[out] | ref | pointer to float array, which will be filled with row values |
returns inverse matrix from current
- Returns:
- inverse matrix
Multiply current matrix with other through operator *.
- Parameters:
-
- Returns:
- multiply result matrix
float* TMatrix::operator[] |
( |
int |
index |
) |
[inline] |
reference operator
- Returns:
- value at certain index
returns transposed matrix from current
- Returns:
- transposed matrix
Friends And Related Function Documentation
ostream& operator<< |
( |
ostream & |
os, |
|
|
const TMatrix & |
m | |
|
) |
| | [friend] |
Print out matrix values as std::ostream object.
- Parameters:
-
| os | reference to std::ostream |
| m | reference to printed matrix |
- Returns:
- reference to new std::ostream object
The documentation for this class was generated from the following files: