Documentation
















  Site Hosted by:

SourceForge.net Logo


Support This Project


ad::Matrix Class Reference

Represents 3D Transformations. More...

#include <matrix.h>

List of all members.

Public Member Functions

 Matrix ()
 Initialize the matrix to the identity Matrix.
 Matrix (const Matrix &arg)
 Initialize the matrix from an existing Matrix.
 Matrix (const float farray[16])
 Initialize the matrix from a array;.
 Matrix (const Quaternion &q, float x=0, float y=0, float z=0)
 Initialize the matrix from an orientation Quaternion and an optional position.
void Set (const Quaternion &q, float x=0, float y=0, float z=0)
 Sets the matrix from an orientation Quaternion and an optional position.
Matrixoperator= (const Matrix &rhs)
 Assigns the matrix to the value of another matrix, and returns the address to this matrix.
Matrixoperator *= (const Matrix &rhs)
 Applies the rhs transformation to the current matrix, stores the result in the current matrix, and returns the address.
Matrix operator * (const Matrix &rhs)
 Transforms the current matrix by another and return the the resulting matrix.
Vector3 operator * (const Vector3 &rhs)
 Matrix * Vector transforms the point by the matrix, and returns the resulting point.
Vector3 Rotate (const Vector3 &v)
 Transforms the point, but ignores offset (used for normals and unit-vectors).

Public Attributes

float m [16]
 Holds the data for the matrix (Column-major).


Detailed Description

Represents 3D Transformations.

Mathematical structure used to store 3D transformations. Good for storing a stack of transformations and can transform points efficiently.
Column-major (Like OpenGL).
0 4 8 12
1 5 9 13
2 6 10 14
3 7 11 15

See also:
ad::Vector3, ad::Quaternion


The documentation for this class was generated from the following files:

© Copyright 2005 John Butterfield.
All Rights Reserved.