FMMatrix33 Class Reference
[Mathematics Classes.]

A 3x3 matrix: use to represent 2D transformations. More...

#include <FMMatrix33.h>

List of all members.

Public Member Functions

 FMMatrix33 (float *_m)
 Creates a FMMatrix33 from the float array.
 FMMatrix33 ()
 Creates an empty FMMatrix33.
 operator float * ()
 Get this FMMatrix33 as an array of floats.
 operator const float * () const
 Get this FMMatrix as an array of floats.
float * operator[] (int a)
 Get a specified row of FMMatrix33 as an array of floats.
FMMatrix33operator= (const FMMatrix33 &copy)
 Assign this FMMatrix33's elements to be the same as that of the given FMMatrix33.
FMMatrix33 Transposed () const
 Gets the transposed of this FMMatrix33.
FMMatrix33 Inverted () const
 Gets the inversion of this FMMatrix33.

Static Public Member Functions

static FMMatrix33 RotationMatrix (float angle)
 Gets the FMMatrix33 representation of a 2D counter-clockwise rotation about the z-axis.
static FMMatrix33 TranslationMatrix (float tx, float ty)
 Gets the FMMatrix33 representation of a 2D translation.
static FMMatrix33 ScaleMatrix (float sx, float sy)
 Gets the FMMatrix33 representation of a 2D scale.
static FMMatrix33 TranslationMatrix (FMVector2 translation)
 Gets the FMMatrix33 representation of a 2D translation.
static FMMatrix33 ScaleMatrix (FMVector2 scale)
 Gets the FMMatrix33 representation of a 2D scale.

Public Attributes

float m [3][3]
 The matrix elements stored in a 2D array.

Static Public Attributes

static FMMatrix33 identity
 The identity FMMatrix33.


Detailed Description

A 3x3 matrix: use to represent 2D transformations.

Not used within FCollada.


Constructor & Destructor Documentation

FMMatrix33::FMMatrix33 float *  _m  ) 
 

Creates a FMMatrix33 from the float array.

The float array stores the elements in the following order: m[0][0], m[1][0], m[2][0], m[0][1], m[1][1], m[2][1], m[0][2], m[1][2], m[2][2].

Parameters:
_m The float array to create the matrix from.

FMMatrix33::FMMatrix33  )  [inline]
 

Creates an empty FMMatrix33.

The default values are non deterministic.


Member Function Documentation

FMMatrix33 FMMatrix33::Inverted  )  const
 

Gets the inversion of this FMMatrix33.

Returns:
The inversion of this FMMatrix.

FMMatrix33::operator const float *  )  const [inline]
 

Get this FMMatrix as an array of floats.

The array contains the elements in the following order: m[0][0], m[0][1], m[0][2], m[1][0], m[1][1], m[1][2], m[2][0], m[2][1], m[2][2].

Returns:
The float array.

FMMatrix33::operator float *  )  [inline]
 

Get this FMMatrix33 as an array of floats.

The array contains the elements in the following order: m[0][0], m[0][1], m[0][2], m[1][0], m[1][1], m[1][2], m[2][0], m[2][1], m[2][2].

Returns:
The float array.

FMMatrix33& FMMatrix33::operator= const FMMatrix33 copy  ) 
 

Assign this FMMatrix33's elements to be the same as that of the given FMMatrix33.

Parameters:
copy The FMMatrix to copy elements from.
Returns:
This FMMatrix.

float* FMMatrix33::operator[] int  a  )  [inline]
 

Get a specified row of FMMatrix33 as an array of floats.

Parameters:
a The row index, starting at 0, of the row to get.
Returns:
The float array of the elements in the specified row.

static FMMatrix33 FMMatrix33::RotationMatrix float  angle  )  [static]
 

Gets the FMMatrix33 representation of a 2D counter-clockwise rotation about the z-axis.

Parameters:
angle The angle of rotation in radians.
Returns:
The rotation FMMatrix.

static FMMatrix33 FMMatrix33::ScaleMatrix FMVector2  scale  )  [inline, static]
 

Gets the FMMatrix33 representation of a 2D scale.

The scale in the x direction is the u componenet of the given FMVector and the scale in the y direction is the v component.

Parameters:
scale The FMVector2 to get the scale components from.
Returns:
The scale FMMatrix33.

static FMMatrix33 FMMatrix33::ScaleMatrix float  sx,
float  sy
[static]
 

Gets the FMMatrix33 representation of a 2D scale.

Parameters:
sx The scale factor in the x direction.
sy The scale factor in the y direction.
Returns:
The scale FMMatrix.

static FMMatrix33 FMMatrix33::TranslationMatrix FMVector2  translation  )  [inline, static]
 

Gets the FMMatrix33 representation of a 2D translation.

The translation in the x direction is the u componenet of the given FMVector2 and the translation in the y direction is the v component.

Parameters:
translation The FMVector2 to get the translation components from.
Returns:
The translation FMMatrix33.

static FMMatrix33 FMMatrix33::TranslationMatrix float  tx,
float  ty
[static]
 

Gets the FMMatrix33 representation of a 2D translation.

Parameters:
tx The translation in the x direction.
ty The translation in the y direction.
Returns:
The translation FMMatrix.

FMMatrix33 FMMatrix33::Transposed  )  const
 

Gets the transposed of this FMMatrix33.

Returns:
The transposed of this FMMatrix.


The documentation for this class was generated from the following file:
Generated on Fri May 12 16:44:44 2006 for FCollada by  doxygen 1.4.6-NO