Macros | |
#define | Mat3Add(a, b, c) |
#define | Mat3Blend(m1, m2, b, m) |
#define | Mat3CompMult(a, b, c) |
#define | Mat3Copy(a, b) |
#define | Mat3Expand(a) |
#define | Mat3Identity(a) |
#define | Mat3MultAdd(a, s, b, c) |
#define | Mat3Scale(a, b, c) |
#define | Mat3Subtract(a, b, c) |
#define | Mat3Trace(a) ((a)[0] + (a)[4] + (a)[8]) |
#define | Mat3Zero(a) memset ((a), 0, 9 * sizeof (a)[0]) |
#define | Mat4toMat3(a, b) |
Functions | |
int | Mat3Decompose (const mat4_t mat, quat_t rot, vec3_t shear, vec3_t scale) |
Decompose a 3x3 column major matrix into its component transformations. More... | |
vec_t | Mat3Determinant (const mat3_t m) |
void | Mat3Init (const quat_t rot, const vec3_t scale, mat3_t mat) |
int | Mat3Inverse (const mat3_t a, mat3_t b) |
void | Mat3Mult (const mat3_t a, const mat3_t b, mat3_t c) |
void | Mat3MultVec (const mat3_t a, const vec3_t b, vec3_t c) |
void | Mat3SymEigen (const mat3_t m, vec3_t e) |
void | Mat3Transpose (const mat3_t a, mat3_t b) |
#define Mat3Add | ( | a, | |
b, | |||
c | |||
) |
#define Mat3Blend | ( | m1, | |
m2, | |||
b, | |||
m | |||
) |
#define Mat3CompMult | ( | a, | |
b, | |||
c | |||
) |
#define Mat3Copy | ( | a, | |
b | |||
) |
#define Mat3Expand | ( | a | ) |
#define Mat3Identity | ( | a | ) |
#define Mat3MultAdd | ( | a, | |
s, | |||
b, | |||
c | |||
) |
#define Mat3Scale | ( | a, | |
b, | |||
c | |||
) |
#define Mat3Subtract | ( | a, | |
b, | |||
c | |||
) |
#define Mat3Trace | ( | a | ) | ((a)[0] + (a)[4] + (a)[8]) |
#define Mat3Zero | ( | a | ) | memset ((a), 0, 9 * sizeof (a)[0]) |
#define Mat4toMat3 | ( | a, | |
b | |||
) |
Decompose a 3x3 column major matrix into its component transformations.
This gives the matrix's rotation as a quaternion, shear (XY, XZ, YZ), and scale. Using the following sequence will give the same result as multiplying v by mat.
QuatMultVec (rot, v, v); VectorShear (shear, v, v); VectorCompMult (scale, v, v);