#include <vector.h>
Public Member Functions | |
Matrix4x4 (void) | |
Constructs an identity 4x4 matrix. | |
Vector4D | operator * (const Vector4D &v) const |
Multiplies a 4x4 matrix with a 4x1 matrix. | |
void | setTranslationVector (const Vector3D &t) |
Sets the translational part of the matrix. | |
float * | toFloatPointer (void) |
Allows direct access to the matrix elements. | |
const float * | toConstFloatPointer (void) const |
Allows direct access to the matrix elements. |
This class can be used to pass around OpenGL style matrices.
void Matrix4x4::setTranslationVector | ( | const Vector3D & | t | ) | [inline] |
Sets the translational part of the matrix.
Because the matrix is column major oder, it sets the elements 12(x), 13(y) and 14(z).
float* Matrix4x4::toFloatPointer | ( | void | ) | [inline] |
Allows direct access to the matrix elements.
You should only use this for reading/writing matrices from/to OpenGL state.
const float* Matrix4x4::toConstFloatPointer | ( | void | ) | const [inline] |
Allows direct access to the matrix elements.
You should only use this for writing matrices to OpenGL state.