C# Class Axiom.Math.Matrix4

Afficher le fichier Open project: mono-soc-2011/axiom Class Usage Examples

Méthodes publiques

Свойство Type Description
m00 Real
m10 Real
m20 Real
m30 Real

Méthodes publiques

Méthode Description
Add ( Matrix4 left, Matrix4 right ) : Matrix4

Used to add two matrices together.

Compose ( Vector3 translation, Vector3 scale, Quaternion orientation ) : Matrix4

Creates a translation Matrix

ComposeInverse ( Vector3 translation, Vector3 scale, Quaternion orientation ) : Matrix4

Creates an inverse translation Matrix

Decompose ( Vector3 &translation, Vector3 &scale, Quaternion &orientation ) : void

Decompose the matrix.

Equals ( object obj ) : bool

Compares this Matrix to another object. This should be done because the equality operators (==, !=) have been overriden by this class.

ExtractRotation ( ) : Axiom.Math.Matrix3

Extract the 3x3 matrix representing the current rotation.

ExtractScale ( ) : Vector3

Extract scaling information.

FromMatrix3 ( Axiom.Math.Matrix3 right ) : Matrix4

Used to allow assignment from a Matrix3 to a Matrix4 object.

GetHashCode ( ) : int

Provides a unique hash code based on the member variables of this class. This should be done because the equality operators (==, !=) have been overriden by this class.

The standard implementation is a simple XOR operation between all local member variables.

GetMatrix3 ( ) : Axiom.Math.Matrix3

Returns a 3x3 portion of this 4x4 matrix.

Inverse ( ) : Matrix4

Returns an inverted matrix.

InverseAffine ( ) : Matrix4

Returns an inverted affine matrix.

MakeFloatArray ( float floats ) : void
MakeRealArray ( Real reals ) : void

Matrix4 ( Real m00, Real m01, Real m02, Real m03, Real m10, Real m11, Real m12, Real m13, Real m20, Real m21, Real m22, Real m23, Real m30, Real m31, Real m32, Real m33 ) : System

Creates a new Matrix4 with all the specified parameters.

Multiply ( Matrix4 left, Matrix4 right ) : Matrix4

Used to multiply (concatenate) two 4x4 Matrices.

Multiply ( Matrix4 matrix, Plane plane ) : Plane

Transforms a plane using the specified transform.

Multiply ( Matrix4 matrix, Vector3 vector ) : Vector3

Transforms the given 3-D vector by the matrix, projecting the result back into w = 1.

This means that the initial w is considered to be 1.0, and then all the tree elements of the resulting 3-D vector are divided by the resulting w.

Subtract ( Matrix4 left, Matrix4 right ) : Matrix4

Used to subtract two matrices.

ToString ( ) : string

Overrides the Object.ToString() method to provide a text representation of a Matrix4.

TransformAffine ( Vector3 v ) : Vector3

3-D Vector transformation specially for affine matrix.

Transforms the given 3-D vector by the matrix, projecting the result back into w = 1. The matrix must be an affine matrix. Matrix4.IsAffine.

TransformAffine ( Vector4 v ) : Vector4

4-D Vector transformation specially for affine matrix.

The matrix must be an affine matrix. Matrix4.IsAffine.

Transpose ( ) : Matrix4

Swap the rows of the matrix with the columns.

operator ( ) : Matrix4

Used to multiply (concatenate) two 4x4 Matrices.

operator ( ) : Plane

Used to multiply a transformation to a Plane.

operator ( ) : Vector3

Transforms the given 3-D vector by the matrix, projecting the result back into w = 1.

This means that the initial w is considered to be 1.0, and then all the tree elements of the resulting 3-D vector are divided by the resulting w.

operator ( ) : bool

Compares two Matrix4 instances for equality.

this ( int index ) : Real

Allows the Matrix to be accessed linearly (m[0] -> m[15]).

This indexer is only provided as a convenience, and is not recommended for use in intensive applications.

this ( int row, int col ) : Real

Allows the Matrix to be accessed like a 2d array (i.e. matrix[2,3])

This indexer is only provided as a convenience, and is not recommended for use in intensive applications.

Private Methods

Méthode Description
Adjoint ( ) : Matrix4

Used to generate the adjoint of this matrix.

Method Details

Add() public static méthode

Used to add two matrices together.
public static Add ( Matrix4 left, Matrix4 right ) : Matrix4
left Matrix4
right Matrix4
Résultat Matrix4

Compose() public static méthode

Creates a translation Matrix
public static Compose ( Vector3 translation, Vector3 scale, Quaternion orientation ) : Matrix4
translation Vector3
scale Vector3
orientation Quaternion
Résultat Matrix4

ComposeInverse() public static méthode

Creates an inverse translation Matrix
public static ComposeInverse ( Vector3 translation, Vector3 scale, Quaternion orientation ) : Matrix4
translation Vector3
scale Vector3
orientation Quaternion
Résultat Matrix4

Decompose() public méthode

Decompose the matrix.
public Decompose ( Vector3 &translation, Vector3 &scale, Quaternion &orientation ) : void
translation Vector3
scale Vector3
orientation Quaternion
Résultat void

Equals() public méthode

Compares this Matrix to another object. This should be done because the equality operators (==, !=) have been overriden by this class.
public Equals ( object obj ) : bool
obj object
Résultat bool

ExtractRotation() public méthode

Extract the 3x3 matrix representing the current rotation.
public ExtractRotation ( ) : Axiom.Math.Matrix3
Résultat Axiom.Math.Matrix3

ExtractScale() public méthode

Extract scaling information.
public ExtractScale ( ) : Vector3
Résultat Vector3

FromMatrix3() public static méthode

Used to allow assignment from a Matrix3 to a Matrix4 object.
public static FromMatrix3 ( Axiom.Math.Matrix3 right ) : Matrix4
right Axiom.Math.Matrix3
Résultat Matrix4

GetHashCode() public méthode

Provides a unique hash code based on the member variables of this class. This should be done because the equality operators (==, !=) have been overriden by this class.

The standard implementation is a simple XOR operation between all local member variables.

public GetHashCode ( ) : int
Résultat int

GetMatrix3() public méthode

Returns a 3x3 portion of this 4x4 matrix.
public GetMatrix3 ( ) : Axiom.Math.Matrix3
Résultat Axiom.Math.Matrix3

Inverse() public méthode

Returns an inverted matrix.
public Inverse ( ) : Matrix4
Résultat Matrix4

InverseAffine() public méthode

Returns an inverted affine matrix.
public InverseAffine ( ) : Matrix4
Résultat Matrix4

MakeFloatArray() public méthode

public MakeFloatArray ( float floats ) : void
floats float
Résultat void

MakeRealArray() public méthode

public MakeRealArray ( Real reals ) : void
reals Real
Résultat void

Matrix4() public méthode

Creates a new Matrix4 with all the specified parameters.
public Matrix4 ( Real m00, Real m01, Real m02, Real m03, Real m10, Real m11, Real m12, Real m13, Real m20, Real m21, Real m22, Real m23, Real m30, Real m31, Real m32, Real m33 ) : System
m00 Real
m01 Real
m02 Real
m03 Real
m10 Real
m11 Real
m12 Real
m13 Real
m20 Real
m21 Real
m22 Real
m23 Real
m30 Real
m31 Real
m32 Real
m33 Real
Résultat System

Multiply() public static méthode

Used to multiply (concatenate) two 4x4 Matrices.
public static Multiply ( Matrix4 left, Matrix4 right ) : Matrix4
left Matrix4
right Matrix4
Résultat Matrix4

Multiply() public static méthode

Transforms a plane using the specified transform.
public static Multiply ( Matrix4 matrix, Plane plane ) : Plane
matrix Matrix4 Transformation matrix.
plane Plane Plane to transform.
Résultat Plane

Multiply() public static méthode

Transforms the given 3-D vector by the matrix, projecting the result back into w = 1.

This means that the initial w is considered to be 1.0, and then all the tree elements of the resulting 3-D vector are divided by the resulting w.

public static Multiply ( Matrix4 matrix, Vector3 vector ) : Vector3
matrix Matrix4 A Matrix4.
vector Vector3 A Vector3.
Résultat Vector3

Subtract() public static méthode

Used to subtract two matrices.
public static Subtract ( Matrix4 left, Matrix4 right ) : Matrix4
left Matrix4
right Matrix4
Résultat Matrix4

ToString() public méthode

Overrides the Object.ToString() method to provide a text representation of a Matrix4.
public ToString ( ) : string
Résultat string

TransformAffine() public méthode

3-D Vector transformation specially for affine matrix.
Transforms the given 3-D vector by the matrix, projecting the result back into w = 1. The matrix must be an affine matrix. Matrix4.IsAffine.
public TransformAffine ( Vector3 v ) : Vector3
v Vector3
Résultat Vector3

TransformAffine() public méthode

4-D Vector transformation specially for affine matrix.
The matrix must be an affine matrix. Matrix4.IsAffine.
public TransformAffine ( Vector4 v ) : Vector4
v Vector4
Résultat Vector4

Transpose() public méthode

Swap the rows of the matrix with the columns.
public Transpose ( ) : Matrix4
Résultat Matrix4

operator() public static méthode

Used to multiply (concatenate) two 4x4 Matrices.
public static operator ( ) : Matrix4
Résultat Matrix4

operator() public static méthode

Used to multiply a transformation to a Plane.
public static operator ( ) : Plane
Résultat Plane

operator() public static méthode

Transforms the given 3-D vector by the matrix, projecting the result back into w = 1.

This means that the initial w is considered to be 1.0, and then all the tree elements of the resulting 3-D vector are divided by the resulting w.

public static operator ( ) : Vector3
Résultat Vector3

operator() public static méthode

Compares two Matrix4 instances for equality.
public static operator ( ) : bool
Résultat bool

this() public méthode

Allows the Matrix to be accessed linearly (m[0] -> m[15]).
This indexer is only provided as a convenience, and is not recommended for use in intensive applications.
public this ( int index ) : Real
index int
Résultat Real

this() public méthode

Allows the Matrix to be accessed like a 2d array (i.e. matrix[2,3])
This indexer is only provided as a convenience, and is not recommended for use in intensive applications.
public this ( int row, int col ) : Real
row int
col int
Résultat Real

Property Details

m00 public_oe property

public Real m00
Résultat Real

m10 public_oe property

public Real m10
Résultat Real

m20 public_oe property

public Real m20
Résultat Real

m30 public_oe property

public Real m30
Résultat Real