|
| CMatrix4 (eConstructor constructor=EM4CONST_IDENTITY) |
| Default constructor. More...
|
|
| CMatrix4 (const T &r0c0, const T &r0c1, const T &r0c2, const T &r0c3, const T &r1c0, const T &r1c1, const T &r1c2, const T &r1c3, const T &r2c0, const T &r2c1, const T &r2c2, const T &r2c3, const T &r3c0, const T &r3c1, const T &r3c2, const T &r3c3) |
| Constructor with value initialization. More...
|
|
| CMatrix4 (const CMatrix4< T > &other, eConstructor constructor=EM4CONST_COPY) |
| Copy constructor. More...
|
|
T & | operator() (const s32 row, const s32 col) |
| Simple operator for directly accessing every element of the matrix. More...
|
|
const T & | operator() (const s32 row, const s32 col) const |
| Simple operator for directly accessing every element of the matrix. More...
|
|
T & | operator[] (u32 index) |
| Simple operator for linearly accessing every element of the matrix. More...
|
|
const T & | operator[] (u32 index) const |
| Simple operator for linearly accessing every element of the matrix. More...
|
|
CMatrix4< T > & | operator= (const CMatrix4< T > &other) |
| Sets this matrix equal to the other matrix. More...
|
|
CMatrix4< T > & | operator= (const T &scalar) |
| Sets all elements of this matrix to the value. More...
|
|
const T * | pointer () const |
| Returns pointer to internal array. More...
|
|
T * | pointer () |
|
bool | operator== (const CMatrix4< T > &other) const |
| Returns true if other matrix is equal to this matrix. More...
|
|
bool | operator!= (const CMatrix4< T > &other) const |
| Returns true if other matrix is not equal to this matrix. More...
|
|
CMatrix4< T > | operator+ (const CMatrix4< T > &other) const |
| Add another matrix. More...
|
|
CMatrix4< T > & | operator+= (const CMatrix4< T > &other) |
| Add another matrix. More...
|
|
CMatrix4< T > | operator- (const CMatrix4< T > &other) const |
| Subtract another matrix. More...
|
|
CMatrix4< T > & | operator-= (const CMatrix4< T > &other) |
| Subtract another matrix. More...
|
|
CMatrix4< T > & | setbyproduct (const CMatrix4< T > &other_a, const CMatrix4< T > &other_b) |
| set this matrix to the product of two matrices More...
|
|
CMatrix4< T > & | setbyproduct_nocheck (const CMatrix4< T > &other_a, const CMatrix4< T > &other_b) |
| Set this matrix to the product of two matrices. More...
|
|
CMatrix4< T > | operator * (const CMatrix4< T > &other) const |
| Multiply by another matrix. More...
|
|
CMatrix4< T > & | operator *= (const CMatrix4< T > &other) |
| Multiply by another matrix. More...
|
|
CMatrix4< T > | operator * (const T &scalar) const |
| Multiply by scalar. More...
|
|
CMatrix4< T > & | operator *= (const T &scalar) |
| Multiply by scalar. More...
|
|
CMatrix4< T > & | makeIdentity () |
| Set matrix to identity. More...
|
|
bool | isIdentity () const |
| Returns true if the matrix is the identity matrix. More...
|
|
bool | isOrthogonal () const |
| Returns true if the matrix is orthogonal. More...
|
|
bool | isIdentity_integer_base () const |
| Returns true if the matrix is the identity matrix. More...
|
|
CMatrix4< T > & | setTranslation (const vector3d< T > &translation) |
| Set the translation of the current matrix. Will erase any previous values. More...
|
|
vector3d< T > | getTranslation () const |
| Gets the current translation. More...
|
|
CMatrix4< T > & | setInverseTranslation (const vector3d< T > &translation) |
| Set the inverse translation of the current matrix. Will erase any previous values. More...
|
|
CMatrix4< T > & | setRotationRadians (const vector3d< T > &rotation) |
| Make a rotation matrix from Euler angles. The 4th row and column are unmodified. More...
|
|
CMatrix4< T > & | setRotationDegrees (const vector3d< T > &rotation) |
| Make a rotation matrix from Euler angles. The 4th row and column are unmodified. More...
|
|
core::vector3d< T > | getRotationDegrees (const vector3d< T > &scale) const |
| Get the rotation, as set by setRotation() when you already know the scale. More...
|
|
core::vector3d< T > | getRotationDegrees () const |
| Returns the rotation, as set by setRotation(). More...
|
|
CMatrix4< T > & | setInverseRotationRadians (const vector3d< T > &rotation) |
| Make an inverted rotation matrix from Euler angles. More...
|
|
CMatrix4< T > & | setInverseRotationDegrees (const vector3d< T > &rotation) |
| Make an inverted rotation matrix from Euler angles. More...
|
|
CMatrix4< T > & | setRotationAxisRadians (const T &angle, const vector3d< T > &axis) |
| Make a rotation matrix from angle and axis, assuming left handed rotation. More...
|
|
CMatrix4< T > & | setScale (const vector3d< T > &scale) |
| Set Scale. More...
|
|
CMatrix4< T > & | setScale (const T scale) |
| Set Scale. More...
|
|
core::vector3d< T > | getScale () const |
| Get Scale. More...
|
|
void | inverseTranslateVect (vector3df &vect) const |
| Translate a vector by the inverse of the translation part of this matrix. More...
|
|
void | inverseRotateVect (vector3df &vect) const |
| Rotate a vector by the inverse of the rotation part of this matrix. More...
|
|
void | rotateVect (vector3df &vect) const |
| Rotate a vector by the rotation part of this matrix. More...
|
|
void | rotateVect (core::vector3df &out, const core::vector3df &in) const |
| An alternate transform vector method, writing into a second vector. More...
|
|
void | rotateVect (T *out, const core::vector3df &in) const |
| An alternate transform vector method, writing into an array of 3 floats. More...
|
|
void | transformVect (vector3df &vect) const |
| Transforms the vector by this matrix. More...
|
|
void | transformVect (vector3df &out, const vector3df &in) const |
| Transforms input vector by this matrix and stores result in output vector. More...
|
|
void | transformVect (T *out, const core::vector3df &in) const |
| An alternate transform vector method, writing into an array of 4 floats. More...
|
|
void | transformVec3 (T *out, const T *in) const |
| An alternate transform vector method, reading from and writing to an array of 3 floats. More...
|
|
void | transformVec4 (T *out, const T *in) const |
| An alternate transform vector method, reading from and writing to an array of 4 floats. More...
|
|
void | translateVect (vector3df &vect) const |
| Translate a vector by the translation part of this matrix. More...
|
|
void | transformPlane (core::plane3d< f32 > &plane) const |
| Transforms a plane by this matrix. More...
|
|
void | transformPlane (const core::plane3d< f32 > &in, core::plane3d< f32 > &out) const |
| Transforms a plane by this matrix. More...
|
|
void | transformBox (core::aabbox3d< f32 > &box) const |
| Transforms a axis aligned bounding box. More...
|
|
void | transformBoxEx (core::aabbox3d< f32 > &box) const |
| Transforms a axis aligned bounding box. More...
|
|
void | multiplyWith1x4Matrix (T *matrix) const |
| Multiplies this matrix by a 1x4 matrix. More...
|
|
bool | makeInverse () |
| Calculates inverse of matrix. Slow. More...
|
|
bool | getInversePrimitive (CMatrix4< T > &out) const |
| Inverts a primitive matrix which only contains a translation and a rotation. More...
|
|
bool | getInverse (CMatrix4< T > &out) const |
| Gets the inverse matrix of this one. More...
|
|
CMatrix4< T > & | buildProjectionMatrixPerspectiveFovRH (f32 fieldOfViewRadians, f32 aspectRatio, f32 zNear, f32 zFar, bool zClipFromZero=true) |
| Builds a right-handed perspective projection matrix based on a field of view. More...
|
|
CMatrix4< T > & | buildProjectionMatrixPerspectiveFovLH (f32 fieldOfViewRadians, f32 aspectRatio, f32 zNear, f32 zFar, bool zClipFromZero=true) |
| Builds a left-handed perspective projection matrix based on a field of view. More...
|
|
CMatrix4< T > & | buildProjectionMatrixPerspectiveFovInfinityLH (f32 fieldOfViewRadians, f32 aspectRatio, f32 zNear, f32 epsilon=0) |
| Builds a left-handed perspective projection matrix based on a field of view, with far plane at infinity. More...
|
|
CMatrix4< T > & | buildProjectionMatrixPerspectiveRH (f32 widthOfViewVolume, f32 heightOfViewVolume, f32 zNear, f32 zFar, bool zClipFromZero=true) |
| Builds a right-handed perspective projection matrix. More...
|
|
CMatrix4< T > & | buildProjectionMatrixPerspectiveLH (f32 widthOfViewVolume, f32 heightOfViewVolume, f32 zNear, f32 zFar, bool zClipFromZero=true) |
| Builds a left-handed perspective projection matrix. More...
|
|
CMatrix4< T > & | buildProjectionMatrixOrthoLH (f32 widthOfViewVolume, f32 heightOfViewVolume, f32 zNear, f32 zFar, bool zClipFromZero=true) |
| Builds a left-handed orthogonal projection matrix. More...
|
|
CMatrix4< T > & | buildProjectionMatrixOrthoRH (f32 widthOfViewVolume, f32 heightOfViewVolume, f32 zNear, f32 zFar, bool zClipFromZero=true) |
| Builds a right-handed orthogonal projection matrix. More...
|
|
CMatrix4< T > & | buildCameraLookAtMatrixLH (const vector3df &position, const vector3df &target, const vector3df &upVector) |
| Builds a left-handed look-at matrix. More...
|
|
CMatrix4< T > & | buildCameraLookAtMatrixRH (const vector3df &position, const vector3df &target, const vector3df &upVector) |
| Builds a right-handed look-at matrix. More...
|
|
CMatrix4< T > & | buildShadowMatrix (const core::vector3df &light, core::plane3df plane, f32 point=1.0f) |
| Builds a matrix that flattens geometry into a plane. More...
|
|
CMatrix4< T > & | buildNDCToDCMatrix (const core::rect< s32 > &area, f32 zScale) |
| Builds a matrix which transforms a normalized Device Coordinate to Device Coordinates. More...
|
|
CMatrix4< T > | interpolate (const core::CMatrix4< T > &b, f32 time) const |
| Creates a new matrix as interpolated matrix from two other ones. More...
|
|
CMatrix4< T > | getTransposed () const |
| Gets transposed matrix. More...
|
|
void | getTransposed (CMatrix4< T > &dest) const |
| Gets transposed matrix. More...
|
|
CMatrix4< T > & | buildRotateFromTo (const core::vector3df &from, const core::vector3df &to) |
| Builds a matrix that rotates from one vector to another. More...
|
|
void | setRotationCenter (const core::vector3df ¢er, const core::vector3df &translate) |
| Builds a combined matrix which translates to a center before rotation and translates from origin afterwards. More...
|
|
void | buildAxisAlignedBillboard (const core::vector3df &camPos, const core::vector3df ¢er, const core::vector3df &translation, const core::vector3df &axis, const core::vector3df &from) |
| Builds a matrix which rotates a source vector to a look vector over an arbitrary axis. More...
|
|
CMatrix4< T > & | buildTextureTransform (f32 rotateRad, const core::vector2df &rotatecenter, const core::vector2df &translate, const core::vector2df &scale) |
| Set to a texture transformation matrix with the given parameters. More...
|
|
CMatrix4< T > & | setTextureRotationCenter (f32 radAngle) |
| Set texture transformation rotation. More...
|
|
CMatrix4< T > & | setTextureTranslate (f32 x, f32 y) |
| Set texture transformation translation. More...
|
|
void | getTextureTranslate (f32 &x, f32 &y) const |
| Get texture transformation translation. More...
|
|
CMatrix4< T > & | setTextureTranslateTransposed (f32 x, f32 y) |
| Set texture transformation translation, using a transposed representation. More...
|
|
CMatrix4< T > & | setTextureScale (f32 sx, f32 sy) |
| Set texture transformation scale. More...
|
|
void | getTextureScale (f32 &sx, f32 &sy) const |
| Get texture transformation scale. More...
|
|
CMatrix4< T > & | setTextureScaleCenter (f32 sx, f32 sy) |
| Set texture transformation scale, and recenter at (0.5,0.5) More...
|
|
CMatrix4< T > & | setM (const T *data) |
| Sets all matrix data members at once. More...
|
|
void | setDefinitelyIdentityMatrix (bool isDefinitelyIdentityMatrix) |
| Sets if the matrix is definitely identity matrix. More...
|
|
bool | getDefinitelyIdentityMatrix () const |
| Gets if the matrix is definitely identity matrix. More...
|
|
bool | equals (const core::CMatrix4< T > &other, const T tolerance=(T) ROUNDING_ERROR_f64) const |
| Compare two matrices using the equal method. More...
|
|
template<class T>
class irr::core::CMatrix4< T >
4x4 matrix. Mostly used as transformation matrix for 3d calculations.
The matrix is a D3D style matrix, row major with translations in the 4th row.
Definition at line 45 of file matrix4.h.