_matrix44 Class Reference
[Math Data Types]
#include <_matrix44.h>
Detailed Description
Generic matrix44 class.(C) 2002 RadonLabs GmbH
Definition at line 28 of file _matrix44.h.
Public Member Functions | |
| _matrix44 () | |
| constructor 1 | |
| _matrix44 (const _vector4 &v0, const _vector4 &v1, const _vector4 &v2, const _vector4 &v3) | |
| constructor 2 | |
| _matrix44 (const _matrix44 &m1) | |
| constructor 3 | |
| _matrix44 (float _m11, float _m12, float _m13, float _m14, float _m21, float _m22, float _m23, float _m24, float _m31, float _m32, float _m33, float _m34, float _m41, float _m42, float _m43, float _m44) | |
| constructor 4 | |
| _matrix44 (const quaternion &q) | |
| construct from quaternion | |
| quaternion | get_quaternion () const |
| convert to quaternion | |
| void | set (const _vector4 &v0, const _vector4 &v1, const _vector4 &v2, const _vector4 &v3) |
| set 1 | |
| void | set (const _matrix44 &m1) |
| set 2 | |
| void | set (float _m11, float _m12, float _m13, float _m14, float _m21, float _m22, float _m23, float _m24, float _m31, float _m32, float _m33, float _m34, float _m41, float _m42, float _m43, float _m44) |
| set 3 | |
| void | set (const quaternion &q) |
| set from quaternion | |
| void | ident () |
| set to identity | |
| void | transpose () |
| transpose | |
| float | det () |
| determinant | |
| void | invert () |
| full invert | |
| void | invert_simple () |
| quick invert (if 3x3 rotation and translation) | |
| void | mult_simple (const _matrix44 &m1) |
| quick multiplication, assumes that M14==M24==M34==0 and M44==1 | |
| _vector3 | transform_coord (const _vector3 &v) const |
| transform vector3, projecting back into w=1 | |
| _vector3 & | x_component () const |
| return x component | |
| _vector3 & | y_component () const |
| return y component | |
| _vector3 & | z_component () const |
| return z component | |
| _vector3 & | pos_component () const |
| return translate component | |
| void | rotate_x (const float a) |
| rotate around global x | |
| void | rotate_y (const float a) |
| rotate around global y | |
| void | rotate_z (const float a) |
| rotate around global z | |
| void | rotate (const _vector3 &vec, float a) |
| rotate about any axis | |
| void | translate (const _vector3 &t) |
| translate | |
| void | set_translation (const _vector3 &t) |
| set absolute translation | |
| void | scale (const _vector3 &s) |
| scale | |
| void | lookatLh (const _vector3 &to, const _vector3 &up) |
| lookat in a left-handed coordinate system | |
| void | lookatRh (const _vector3 &to, const _vector3 &up) |
| lookat in a right-handed coordinate system | |
| void | perspFovLh (float fovY, float aspect, float zn, float zf) |
| create left-handed field-of-view perspective projection matrix | |
| void | perspFovRh (float fovY, float aspect, float zn, float zf) |
| create right-handed field-of-view perspective projection matrix | |
| void | perspOffCenterLh (float minX, float maxX, float minY, float maxY, float zn, float zf) |
| create off-center left-handed perspective projection matrix | |
| void | perspOffCenterRh (float minX, float maxX, float minY, float maxY, float zn, float zf) |
| create off-center right-handed perspective projection matrix | |
| void | orthoLh (float w, float h, float zn, float zf) |
| create left-handed orthogonal projection matrix | |
| void | orthoRh (float w, float h, float zn, float zf) |
| create right-handed orthogonal projection matrix | |
| void | billboard (const _vector3 &to, const _vector3 &up) |
| restricted lookat | |
| void | operator *= (const _matrix44 &m1) |
| inplace matrix multiply | |
| void | mult (const _vector4 &src, _vector4 &dst) const |
| multiply source vector into target vector, eliminates tmp vector | |
| void | mult (const _vector3 &src, _vector3 &dst) const |
| multiply source vector into target vector, eliminates tmp vector | |
| vector3 | mult_divw (const _vector3 &v) const |
| multiply and divide by w | |
| void | weighted_madd (const _vector3 &src, _vector3 &dst, float weight) const |
| fast multiply-add with weighting | |
Public Attributes | |
| float | m [4][4] |
Static Public Attributes | |
| static const _matrix44 | identity = _matrix44() |
| static const _matrix44 | ortho |
Constructor & Destructor Documentation
|
|
constructor 1
Definition at line 133 of file _matrix44.h. |
|
||||||||||||||||||||
|
constructor 2
Definition at line 142 of file _matrix44.h. |
|
|
constructor 3
Definition at line 154 of file _matrix44.h. |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
constructor 4
Definition at line 163 of file _matrix44.h. |
|
|
construct from quaternion
Definition at line 178 of file _matrix44.h. |
Member Function Documentation
|
|
convert to quaternion convert orientation of 4x4 matrix into quaterion, 4x4 matrix must not be scaled! Definition at line 210 of file _matrix44.h. |
|
||||||||||||||||||||
|
set 1
Definition at line 247 of file _matrix44.h. |
|
|
set 2
Definition at line 260 of file _matrix44.h. |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
set 3
Definition at line 270 of file _matrix44.h. |
|
|
set from quaternion
Definition at line 286 of file _matrix44.h. |
|
|
set to identity
Definition at line 316 of file _matrix44.h. |
|
|
transpose
Definition at line 326 of file _matrix44.h. |
|
|
determinant
Definition at line 343 of file _matrix44.h. |
|
|
full invert
Definition at line 359 of file _matrix44.h. |
|
|
quick invert (if 3x3 rotation and translation) inverts a 4x4 matrix consisting of a 3x3 rotation matrix and a translation (eg. everything that has [0,0,0,1] as the rightmost column) MUCH cheaper then a real 4x4 inversion Definition at line 391 of file _matrix44.h. |
|
|
quick multiplication, assumes that M14==M24==M34==0 and M44==1 optimized multiplication, assumes that M14==M24==M34==0 AND M44==1 Definition at line 421 of file _matrix44.h. |
|
|
transform vector3, projecting back into w=1 Transforms a vector by the matrix, projecting the result back into w=1. Definition at line 448 of file _matrix44.h. |
|
|
return x component
Definition at line 463 of file _matrix44.h. |
|
|
return y component
Definition at line 474 of file _matrix44.h. |
|
|
return z component
Definition at line 485 of file _matrix44.h. |
|
|
return translate component
Definition at line 496 of file _matrix44.h. |
|
|
rotate around global x
Definition at line 506 of file _matrix44.h. |
|
|
rotate around global y
Definition at line 524 of file _matrix44.h. |
|
|
rotate around global z
Definition at line 542 of file _matrix44.h. |
|
||||||||||||
|
rotate about any axis
Definition at line 759 of file _matrix44.h. |
|
|
translate
Definition at line 560 of file _matrix44.h. |
|
|
set absolute translation
Definition at line 572 of file _matrix44.h. |
|
|
scale
Definition at line 584 of file _matrix44.h. |
|
||||||||||||
|
lookat in a left-handed coordinate system
Definition at line 618 of file _matrix44.h. |
|
||||||||||||
|
lookat in a right-handed coordinate system
Definition at line 600 of file _matrix44.h. |
|
||||||||||||||||||||
|
create left-handed field-of-view perspective projection matrix
Definition at line 636 of file _matrix44.h. |
|
||||||||||||||||||||
|
create right-handed field-of-view perspective projection matrix
Definition at line 651 of file _matrix44.h. |
|
||||||||||||||||||||||||||||
|
create off-center left-handed perspective projection matrix
Definition at line 666 of file _matrix44.h. |
|
||||||||||||||||||||||||||||
|
create off-center right-handed perspective projection matrix
Definition at line 679 of file _matrix44.h. |
|
||||||||||||||||||||
|
create left-handed orthogonal projection matrix
Definition at line 692 of file _matrix44.h. |
|
||||||||||||||||||||
|
create right-handed orthogonal projection matrix
Definition at line 705 of file _matrix44.h. |
|
||||||||||||
|
restricted lookat
Definition at line 718 of file _matrix44.h. |
|
|
inplace matrix multiply
Definition at line 738 of file _matrix44.h. |
|
||||||||||||
|
multiply source vector into target vector, eliminates tmp vector
Definition at line 785 of file _matrix44.h. |
|
||||||||||||
|
multiply source vector into target vector, eliminates tmp vector
Definition at line 798 of file _matrix44.h. |
|
|
multiply and divide by w
Definition at line 881 of file _matrix44.h. |
|
||||||||||||||||
|
fast multiply-add with weighting Perform a multiply-add with weighting (this is quite specialized for CPU-skinning) Definition at line 812 of file _matrix44.h. |
Member Data Documentation
|
|
Definition at line 3 of file _matrix44.cc. |
|
|
Initial value: _matrix44(0.5f, 0.0f, 0.0f, 0.0f, 0.0f, 0.6667f, 0.0f, 0.0f, 0.0f, 0.0f, -0.5f, 0.0f, 0.0f, 0.0f, 0.5f, 1.0f) Definition at line 5 of file _matrix44.cc. |
|
|
Definition at line 126 of file _matrix44.h. |
The documentation for this class was generated from the following files: