All Classes |Grouped Classes |Index

Class CL_Mat3

3D matrix More...

Derived from:

None

Derived by:

None

Group:

Math (Core)

#include <ClanLib/core.h>

Class Members:

Construction:

CL_Mat3

Constructs a 3x3 matrix (uninitialised)

null

identity

rotate

Create a rotation matrix.

multiply

Multiply 2 matrices.

add

Add 2 matrices.

subtract

Subtract 2 matrices.

adjoint

Calculate the adjoint (or known as Adjugate or Conjugate Transpose) of a matrix.

inverse

Calculate the matrix inverse of a matrix.

transpose

Calculate the transpose of a matrix.


Attributes:

matrix


Operations:

multiply

Multiply this matrix and a specified matrix.

add

Add this matrix and a specified matrix.

subtract

Subtract this matrix and a specified matrix.

det

Calculate the matrix determinant.

adjoint

Creates the adjoint (or known as adjugate) of the matrix.

inverse

Create the matrix inverse. (Returns a zero matrix if the determinent = 0)

transpose

Calculate the transpose of this matrix.


Operators:

operator Type const *

Operator that returns the matrix as a array.

operator Type *

Operator that returns the matrix as a array.

operator[]

Operator that returns the matrix cell at the given index.

operator*

Multiplication operator.

operator+

Addition operator.

operator-

Subtraction operator.

operator==

Equality operator.

operator!=

Not-equal operator.

Detailed description:

These matrix templates are defined for: int (CL_Mat3i), float (CL_Mat3f), double (CL_Mat3d)