The Open Toolkit library  1.1
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Properties | List of all members
OpenTK.Matrix3x4d Struct Reference

Represents a 3x4 Matrix More...

Inherits IEquatable< Matrix3x4d >.

Public Member Functions

 Matrix3x4d (Vector4d row0, Vector4d row1, Vector4d row2)
 Constructs a new instance. More...
 
 Matrix3x4d (double m00, double m01, double m02, double m03, double m10, double m11, double m12, double m13, double m20, double m21, double m22, double m23)
 Constructs a new instance. More...
 
void Invert ()
 Converts this instance into its inverse. More...
 
override string ToString ()
 Returns a System.String that represents the current Matrix4. More...
 
override int GetHashCode ()
 Returns the hashcode for this instance. More...
 
override bool Equals (object obj)
 Indicates whether this instance and a specified object are equal. More...
 
bool Equals (Matrix3x4d other)
 Indicates whether the current matrix is equal to another matrix. More...
 

Static Public Member Functions

static void CreateFromAxisAngle (Vector3d axis, double angle, out Matrix3x4d result)
 Build a rotation matrix from the specified axis/angle rotation. More...
 
static Matrix3x4d CreateFromAxisAngle (Vector3d axis, double angle)
 Build a rotation matrix from the specified axis/angle rotation. More...
 
static void CreateFromQuaternion (ref Quaternion q, out Matrix3x4d result)
 Builds a rotation matrix from a quaternion. More...
 
static Matrix3x4d CreateFromQuaternion (Quaternion q)
 Builds a rotation matrix from a quaternion. More...
 
static void CreateRotationX (double angle, out Matrix3x4d result)
 Builds a rotation matrix for a rotation around the x-axis. More...
 
static Matrix3x4d CreateRotationX (double angle)
 Builds a rotation matrix for a rotation around the x-axis. More...
 
static void CreateRotationY (double angle, out Matrix3x4d result)
 Builds a rotation matrix for a rotation around the y-axis. More...
 
static Matrix3x4d CreateRotationY (double angle)
 Builds a rotation matrix for a rotation around the y-axis. More...
 
static void CreateRotationZ (double angle, out Matrix3x4d result)
 Builds a rotation matrix for a rotation around the z-axis. More...
 
static Matrix3x4d CreateRotationZ (double angle)
 Builds a rotation matrix for a rotation around the z-axis. More...
 
static void CreateTranslation (double x, double y, double z, out Matrix3x4d result)
 Creates a translation matrix. More...
 
static void CreateTranslation (ref Vector3d vector, out Matrix3x4d result)
 Creates a translation matrix. More...
 
static Matrix3x4d CreateTranslation (double x, double y, double z)
 Creates a translation matrix. More...
 
static Matrix3x4d CreateTranslation (Vector3d vector)
 Creates a translation matrix. More...
 
static Matrix3x4d CreateScale (double scale)
 Build a scaling matrix More...
 
static Matrix3x4d CreateScale (Vector3d scale)
 Build a scaling matrix More...
 
static Matrix3x4d CreateScale (double x, double y, double z)
 Build a scaling matrix More...
 
static Matrix3d Mult (Matrix3x4d left, Matrix4x3d right)
 Multiplies two instances. More...
 
static void Mult (ref Matrix3x4d left, ref Matrix4x3d right, out Matrix3d result)
 Multiplies two instances. More...
 
static Matrix3x4d Mult (Matrix3x4d left, Matrix3x4d right)
 Multiplies two instances. More...
 
static void Mult (ref Matrix3x4d left, ref Matrix3x4d right, out Matrix3x4d result)
 Multiplies two instances. More...
 
static Matrix3x4d Mult (Matrix3x4d left, double right)
 Multiplies an instance by a scalar. More...
 
static void Mult (ref Matrix3x4d left, double right, out Matrix3x4d result)
 Multiplies an instance by a scalar. More...
 
static Matrix3x4d Add (Matrix3x4d left, Matrix3x4d right)
 Adds two instances. More...
 
static void Add (ref Matrix3x4d left, ref Matrix3x4d right, out Matrix3x4d result)
 Adds two instances. More...
 
static Matrix3x4d Subtract (Matrix3x4d left, Matrix3x4d right)
 Subtracts one instance from another. More...
 
static void Subtract (ref Matrix3x4d left, ref Matrix3x4d right, out Matrix3x4d result)
 Subtracts one instance from another. More...
 
static Matrix3x4d Invert (Matrix3x4d mat)
 Calculate the inverse of the given matrix More...
 
static void Invert (ref Matrix3x4d mat, out Matrix3x4d result)
 Calculate the inverse of the given matrix More...
 
static Matrix4x3d Transpose (Matrix3x4d mat)
 Calculate the transpose of the given matrix More...
 
static void Transpose (ref Matrix3x4d mat, out Matrix4x3d result)
 Calculate the transpose of the given matrix More...
 
static Matrix3d operator* (Matrix3x4d left, Matrix4x3d right)
 Matrix multiplication More...
 
static Matrix3x4d operator* (Matrix3x4d left, Matrix3x4d right)
 Matrix multiplication More...
 
static Matrix3x4d operator* (Matrix3x4d left, double right)
 Matrix-scalar multiplication More...
 
static Matrix3x4d operator+ (Matrix3x4d left, Matrix3x4d right)
 Matrix addition More...
 
static Matrix3x4d operator- (Matrix3x4d left, Matrix3x4d right)
 Matrix subtraction More...
 
static bool operator== (Matrix3x4d left, Matrix3x4d right)
 Compares two instances for equality. More...
 
static bool operator!= (Matrix3x4d left, Matrix3x4d right)
 Compares two instances for inequality. More...
 

Public Attributes

Vector4d Row0
 Top row of the matrix More...
 
Vector4d Row1
 2nd row of the matrix More...
 
Vector4d Row2
 Bottom row of the matrix More...
 

Static Public Attributes

static Matrix3x4d Zero = new Matrix3x4d(Vector4d.Zero, Vector4d.Zero, Vector4d.Zero)
 The zero matrix More...
 

Properties

Vector3d Column0 [get]
 Gets the first column of this matrix. More...
 
Vector3d Column1 [get]
 Gets the second column of this matrix. More...
 
Vector3d Column2 [get]
 Gets the third column of this matrix. More...
 
Vector3d Column3 [get]
 Gets the fourth column of this matrix. More...
 
double M11 [get, set]
 Gets or sets the value at row 1, column 1 of this instance. More...
 
double M12 [get, set]
 Gets or sets the value at row 1, column 2 of this instance. More...
 
double M13 [get, set]
 Gets or sets the value at row 1, column 3 of this instance. More...
 
double M14 [get, set]
 Gets or sets the value at row 1, column 4 of this instance. More...
 
double M21 [get, set]
 Gets or sets the value at row 2, column 1 of this instance. More...
 
double M22 [get, set]
 Gets or sets the value at row 2, column 2 of this instance. More...
 
double M23 [get, set]
 Gets or sets the value at row 2, column 3 of this instance. More...
 
double M24 [get, set]
 Gets or sets the value at row 2, column 4 of this instance. More...
 
double M31 [get, set]
 Gets or sets the value at row 3, column 1 of this instance. More...
 
double M32 [get, set]
 Gets or sets the value at row 3, column 2 of this instance. More...
 
double M33 [get, set]
 Gets or sets the value at row 3, column 3 of this instance. More...
 
double M34 [get, set]
 Gets or sets the value at row 3, column 4 of this instance. More...
 
Vector3d Diagonal [get, set]
 Gets or sets the values along the main diagonal of the matrix. More...
 
double Trace [get]
 Gets the trace of the matrix, the sum of the values along the diagonal. More...
 
double this[int rowIndex, int columnIndex] [get, set]
 Gets or sets the value at a specified row and column. More...
 

Detailed Description

Represents a 3x4 Matrix

Constructor & Destructor Documentation

OpenTK.Matrix3x4d.Matrix3x4d ( Vector4d  row0,
Vector4d  row1,
Vector4d  row2 
)

Constructs a new instance.

Parameters
row0Top row of the matrix
row1Second row of the matrix
row2Bottom row of the matrix
OpenTK.Matrix3x4d.Matrix3x4d ( double  m00,
double  m01,
double  m02,
double  m03,
double  m10,
double  m11,
double  m12,
double  m13,
double  m20,
double  m21,
double  m22,
double  m23 
)

Constructs a new instance.

Parameters
m00First item of the first row of the matrix.
m01Second item of the first row of the matrix.
m02Third item of the first row of the matrix.
m03Fourth item of the first row of the matrix.
m10First item of the second row of the matrix.
m11Second item of the second row of the matrix.
m12Third item of the second row of the matrix.
m13Fourth item of the second row of the matrix.
m20First item of the third row of the matrix.
m21Second item of the third row of the matrix.
m22Third item of the third row of the matrix.
m23First item of the third row of the matrix.

Member Function Documentation

static Matrix3x4d OpenTK.Matrix3x4d.Add ( Matrix3x4d  left,
Matrix3x4d  right 
)
static

Adds two instances.

Parameters
leftThe left operand of the addition.
rightThe right operand of the addition.
Returns
A new instance that is the result of the addition.
static void OpenTK.Matrix3x4d.Add ( ref Matrix3x4d  left,
ref Matrix3x4d  right,
out Matrix3x4d  result 
)
static

Adds two instances.

Parameters
leftThe left operand of the addition.
rightThe right operand of the addition.
resultA new instance that is the result of the addition.
static void OpenTK.Matrix3x4d.CreateFromAxisAngle ( Vector3d  axis,
double  angle,
out Matrix3x4d  result 
)
static

Build a rotation matrix from the specified axis/angle rotation.

Parameters
axisThe axis to rotate about.
angleAngle in radians to rotate counter-clockwise (looking in the direction of the given axis).
resultA matrix instance.
static Matrix3x4d OpenTK.Matrix3x4d.CreateFromAxisAngle ( Vector3d  axis,
double  angle 
)
static

Build a rotation matrix from the specified axis/angle rotation.

Parameters
axisThe axis to rotate about.
angleAngle in radians to rotate counter-clockwise (looking in the direction of the given axis).
Returns
A matrix instance.
static void OpenTK.Matrix3x4d.CreateFromQuaternion ( ref Quaternion  q,
out Matrix3x4d  result 
)
static

Builds a rotation matrix from a quaternion.

Parameters
qThe quaternion to rotate by.
resultA matrix instance.
static Matrix3x4d OpenTK.Matrix3x4d.CreateFromQuaternion ( Quaternion  q)
static

Builds a rotation matrix from a quaternion.

Parameters
qThe quaternion to rotate by.
Returns
A matrix instance.
static void OpenTK.Matrix3x4d.CreateRotationX ( double  angle,
out Matrix3x4d  result 
)
static

Builds a rotation matrix for a rotation around the x-axis.

Parameters
angleThe counter-clockwise angle in radians.
resultThe resulting Matrix4 instance.
static Matrix3x4d OpenTK.Matrix3x4d.CreateRotationX ( double  angle)
static

Builds a rotation matrix for a rotation around the x-axis.

Parameters
angleThe counter-clockwise angle in radians.
Returns
The resulting Matrix4 instance.
static void OpenTK.Matrix3x4d.CreateRotationY ( double  angle,
out Matrix3x4d  result 
)
static

Builds a rotation matrix for a rotation around the y-axis.

Parameters
angleThe counter-clockwise angle in radians.
resultThe resulting Matrix4 instance.
static Matrix3x4d OpenTK.Matrix3x4d.CreateRotationY ( double  angle)
static

Builds a rotation matrix for a rotation around the y-axis.

Parameters
angleThe counter-clockwise angle in radians.
Returns
The resulting Matrix4 instance.
static void OpenTK.Matrix3x4d.CreateRotationZ ( double  angle,
out Matrix3x4d  result 
)
static

Builds a rotation matrix for a rotation around the z-axis.

Parameters
angleThe counter-clockwise angle in radians.
resultThe resulting Matrix4 instance.
static Matrix3x4d OpenTK.Matrix3x4d.CreateRotationZ ( double  angle)
static

Builds a rotation matrix for a rotation around the z-axis.

Parameters
angleThe counter-clockwise angle in radians.
Returns
The resulting Matrix4 instance.
static Matrix3x4d OpenTK.Matrix3x4d.CreateScale ( double  scale)
static

Build a scaling matrix

Parameters
scaleSingle scale factor for x,y and z axes
Returns
A scaling matrix
static Matrix3x4d OpenTK.Matrix3x4d.CreateScale ( Vector3d  scale)
static

Build a scaling matrix

Parameters
scaleScale factors for x,y and z axes
Returns
A scaling matrix
static Matrix3x4d OpenTK.Matrix3x4d.CreateScale ( double  x,
double  y,
double  z 
)
static

Build a scaling matrix

Parameters
xScale factor for x-axis
yScale factor for y-axis
zScale factor for z-axis
Returns
A scaling matrix
static void OpenTK.Matrix3x4d.CreateTranslation ( double  x,
double  y,
double  z,
out Matrix3x4d  result 
)
static

Creates a translation matrix.

Parameters
xX translation.
yY translation.
zZ translation.
resultThe resulting Matrix4 instance.
static void OpenTK.Matrix3x4d.CreateTranslation ( ref Vector3d  vector,
out Matrix3x4d  result 
)
static

Creates a translation matrix.

Parameters
vectorThe translation vector.
resultThe resulting Matrix4 instance.
static Matrix3x4d OpenTK.Matrix3x4d.CreateTranslation ( double  x,
double  y,
double  z 
)
static

Creates a translation matrix.

Parameters
xX translation.
yY translation.
zZ translation.
Returns
The resulting Matrix4 instance.
static Matrix3x4d OpenTK.Matrix3x4d.CreateTranslation ( Vector3d  vector)
static

Creates a translation matrix.

Parameters
vectorThe translation vector.
Returns
The resulting Matrix4 instance.
override bool OpenTK.Matrix3x4d.Equals ( object  obj)

Indicates whether this instance and a specified object are equal.

Parameters
objThe object to compare to.
Returns
True if the instances are equal; false otherwise.
bool OpenTK.Matrix3x4d.Equals ( Matrix3x4d  other)

Indicates whether the current matrix is equal to another matrix.

Parameters
otherAn matrix to compare with this matrix.
Returns
true if the current matrix is equal to the matrix parameter; otherwise, false.
override int OpenTK.Matrix3x4d.GetHashCode ( )

Returns the hashcode for this instance.

Returns
A System.Int32 containing the unique hashcode for this instance.
void OpenTK.Matrix3x4d.Invert ( )

Converts this instance into its inverse.

static Matrix3x4d OpenTK.Matrix3x4d.Invert ( Matrix3x4d  mat)
static

Calculate the inverse of the given matrix

Parameters
matThe matrix to invert
Returns
The inverse of the given matrix if it has one, or the input if it is singular
Exceptions
InvalidOperationExceptionThrown if the Matrix4 is singular.
static void OpenTK.Matrix3x4d.Invert ( ref Matrix3x4d  mat,
out Matrix3x4d  result 
)
static

Calculate the inverse of the given matrix

Parameters
matThe matrix to invert
resultThe inverse of the given matrix if it has one, or the input if it is singular
Exceptions
InvalidOperationExceptionThrown if the Matrix4 is singular.
static Matrix3d OpenTK.Matrix3x4d.Mult ( Matrix3x4d  left,
Matrix4x3d  right 
)
static

Multiplies two instances.

Parameters
leftThe left operand of the multiplication.
rightThe right operand of the multiplication.
Returns
A new instance that is the result of the multiplication
static void OpenTK.Matrix3x4d.Mult ( ref Matrix3x4d  left,
ref Matrix4x3d  right,
out Matrix3d  result 
)
static

Multiplies two instances.

Parameters
leftThe left operand of the multiplication.
rightThe right operand of the multiplication.
resultA new instance that is the result of the multiplication
static Matrix3x4d OpenTK.Matrix3x4d.Mult ( Matrix3x4d  left,
Matrix3x4d  right 
)
static

Multiplies two instances.

Parameters
leftThe left operand of the multiplication.
rightThe right operand of the multiplication.
Returns
A new instance that is the result of the multiplication
static void OpenTK.Matrix3x4d.Mult ( ref Matrix3x4d  left,
ref Matrix3x4d  right,
out Matrix3x4d  result 
)
static

Multiplies two instances.

Parameters
leftThe left operand of the multiplication.
rightThe right operand of the multiplication.
resultA new instance that is the result of the multiplication
static Matrix3x4d OpenTK.Matrix3x4d.Mult ( Matrix3x4d  left,
double  right 
)
static

Multiplies an instance by a scalar.

Parameters
leftThe left operand of the multiplication.
rightThe right operand of the multiplication.
Returns
A new instance that is the result of the multiplication
static void OpenTK.Matrix3x4d.Mult ( ref Matrix3x4d  left,
double  right,
out Matrix3x4d  result 
)
static

Multiplies an instance by a scalar.

Parameters
leftThe left operand of the multiplication.
rightThe right operand of the multiplication.
resultA new instance that is the result of the multiplication
static bool OpenTK.Matrix3x4d.operator!= ( Matrix3x4d  left,
Matrix3x4d  right 
)
static

Compares two instances for inequality.

Parameters
leftThe first instance.
rightThe second instance.
Returns
True, if left does not equal right; false otherwise.
static Matrix3d OpenTK.Matrix3x4d.operator* ( Matrix3x4d  left,
Matrix4x3d  right 
)
static

Matrix multiplication

Parameters
leftleft-hand operand
rightright-hand operand
Returns
A new Matrix3d which holds the result of the multiplication
static Matrix3x4d OpenTK.Matrix3x4d.operator* ( Matrix3x4d  left,
Matrix3x4d  right 
)
static

Matrix multiplication

Parameters
leftleft-hand operand
rightright-hand operand
Returns
A new Matrix3x4d which holds the result of the multiplication
static Matrix3x4d OpenTK.Matrix3x4d.operator* ( Matrix3x4d  left,
double  right 
)
static

Matrix-scalar multiplication

Parameters
leftleft-hand operand
rightright-hand operand
Returns
A new Matrix3x4d which holds the result of the multiplication
static Matrix3x4d OpenTK.Matrix3x4d.operator+ ( Matrix3x4d  left,
Matrix3x4d  right 
)
static

Matrix addition

Parameters
leftleft-hand operand
rightright-hand operand
Returns
A new Matrix3x4d which holds the result of the addition
static Matrix3x4d OpenTK.Matrix3x4d.operator- ( Matrix3x4d  left,
Matrix3x4d  right 
)
static

Matrix subtraction

Parameters
leftleft-hand operand
rightright-hand operand
Returns
A new Matrix3x4d which holds the result of the subtraction
static bool OpenTK.Matrix3x4d.operator== ( Matrix3x4d  left,
Matrix3x4d  right 
)
static

Compares two instances for equality.

Parameters
leftThe first instance.
rightThe second instance.
Returns
True, if left equals right; false otherwise.
static Matrix3x4d OpenTK.Matrix3x4d.Subtract ( Matrix3x4d  left,
Matrix3x4d  right 
)
static

Subtracts one instance from another.

Parameters
leftThe left operand of the subraction.
rightThe right operand of the subraction.
Returns
A new instance that is the result of the subraction.
static void OpenTK.Matrix3x4d.Subtract ( ref Matrix3x4d  left,
ref Matrix3x4d  right,
out Matrix3x4d  result 
)
static

Subtracts one instance from another.

Parameters
leftThe left operand of the subraction.
rightThe right operand of the subraction.
resultA new instance that is the result of the subraction.
override string OpenTK.Matrix3x4d.ToString ( )

Returns a System.String that represents the current Matrix4.

Returns
The string representation of the matrix.
static Matrix4x3d OpenTK.Matrix3x4d.Transpose ( Matrix3x4d  mat)
static

Calculate the transpose of the given matrix

Parameters
matThe matrix to transpose
Returns
The transpose of the given matrix
static void OpenTK.Matrix3x4d.Transpose ( ref Matrix3x4d  mat,
out Matrix4x3d  result 
)
static

Calculate the transpose of the given matrix

Parameters
matThe matrix to transpose
resultThe result of the calculation

Member Data Documentation

Vector4d OpenTK.Matrix3x4d.Row0

Top row of the matrix

Vector4d OpenTK.Matrix3x4d.Row1

2nd row of the matrix

Vector4d OpenTK.Matrix3x4d.Row2

Bottom row of the matrix

Matrix3x4d OpenTK.Matrix3x4d.Zero = new Matrix3x4d(Vector4d.Zero, Vector4d.Zero, Vector4d.Zero)
static

The zero matrix

Property Documentation

Vector3d OpenTK.Matrix3x4d.Column0
get

Gets the first column of this matrix.

Vector3d OpenTK.Matrix3x4d.Column1
get

Gets the second column of this matrix.

Vector3d OpenTK.Matrix3x4d.Column2
get

Gets the third column of this matrix.

Vector3d OpenTK.Matrix3x4d.Column3
get

Gets the fourth column of this matrix.

Vector3d OpenTK.Matrix3x4d.Diagonal
getset

Gets or sets the values along the main diagonal of the matrix.

double OpenTK.Matrix3x4d.M11
getset

Gets or sets the value at row 1, column 1 of this instance.

double OpenTK.Matrix3x4d.M12
getset

Gets or sets the value at row 1, column 2 of this instance.

double OpenTK.Matrix3x4d.M13
getset

Gets or sets the value at row 1, column 3 of this instance.

double OpenTK.Matrix3x4d.M14
getset

Gets or sets the value at row 1, column 4 of this instance.

double OpenTK.Matrix3x4d.M21
getset

Gets or sets the value at row 2, column 1 of this instance.

double OpenTK.Matrix3x4d.M22
getset

Gets or sets the value at row 2, column 2 of this instance.

double OpenTK.Matrix3x4d.M23
getset

Gets or sets the value at row 2, column 3 of this instance.

double OpenTK.Matrix3x4d.M24
getset

Gets or sets the value at row 2, column 4 of this instance.

double OpenTK.Matrix3x4d.M31
getset

Gets or sets the value at row 3, column 1 of this instance.

double OpenTK.Matrix3x4d.M32
getset

Gets or sets the value at row 3, column 2 of this instance.

double OpenTK.Matrix3x4d.M33
getset

Gets or sets the value at row 3, column 3 of this instance.

double OpenTK.Matrix3x4d.M34
getset

Gets or sets the value at row 3, column 4 of this instance.

double OpenTK.Matrix3x4d.this[int rowIndex, int columnIndex]
getset

Gets or sets the value at a specified row and column.

double OpenTK.Matrix3x4d.Trace
get

Gets the trace of the matrix, the sum of the values along the diagonal.