The Open Toolkit library
1.0
|
Represents a 3x4 Matrix More...
Inherits IEquatable< Matrix3x4 >.
Public Member Functions | |
Matrix3x4 (Vector4 row0, Vector4 row1, Vector4 row2) | |
Constructs a new instance. More... | |
Matrix3x4 (float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13, float m20, float m21, float m22, float 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 (Matrix3x4 other) |
Indicates whether the current matrix is equal to another matrix. More... | |
Static Public Member Functions | |
static void | CreateFromAxisAngle (Vector3 axis, float angle, out Matrix3x4 result) |
Build a rotation matrix from the specified axis/angle rotation. More... | |
static Matrix3x4 | CreateFromAxisAngle (Vector3 axis, float angle) |
Build a rotation matrix from the specified axis/angle rotation. More... | |
static void | CreateFromQuaternion (ref Quaternion q, out Matrix3x4 result) |
Builds a rotation matrix from a quaternion. More... | |
static Matrix3x4 | CreateFromQuaternion (Quaternion q) |
Builds a rotation matrix from a quaternion. More... | |
static void | CreateRotationX (float angle, out Matrix3x4 result) |
Builds a rotation matrix for a rotation around the x-axis. More... | |
static Matrix3x4 | CreateRotationX (float angle) |
Builds a rotation matrix for a rotation around the x-axis. More... | |
static void | CreateRotationY (float angle, out Matrix3x4 result) |
Builds a rotation matrix for a rotation around the y-axis. More... | |
static Matrix3x4 | CreateRotationY (float angle) |
Builds a rotation matrix for a rotation around the y-axis. More... | |
static void | CreateRotationZ (float angle, out Matrix3x4 result) |
Builds a rotation matrix for a rotation around the z-axis. More... | |
static Matrix3x4 | CreateRotationZ (float angle) |
Builds a rotation matrix for a rotation around the z-axis. More... | |
static void | CreateTranslation (float x, float y, float z, out Matrix3x4 result) |
Creates a translation matrix. More... | |
static void | CreateTranslation (ref Vector3 vector, out Matrix3x4 result) |
Creates a translation matrix. More... | |
static Matrix3x4 | CreateTranslation (float x, float y, float z) |
Creates a translation matrix. More... | |
static Matrix3x4 | CreateTranslation (Vector3 vector) |
Creates a translation matrix. More... | |
static Matrix3x4 | CreateScale (float scale) |
Build a scaling matrix More... | |
static Matrix3x4 | CreateScale (Vector3 scale) |
Build a scaling matrix More... | |
static Matrix3x4 | CreateScale (float x, float y, float z) |
Build a scaling matrix More... | |
static Matrix3 | Mult (Matrix3x4 left, Matrix4x3 right) |
Multiplies two instances. More... | |
static void | Mult (ref Matrix3x4 left, ref Matrix4x3 right, out Matrix3 result) |
Multiplies two instances. More... | |
static Matrix3x4 | Mult (Matrix3x4 left, Matrix3x4 right) |
Multiplies two instances. More... | |
static void | Mult (ref Matrix3x4 left, ref Matrix3x4 right, out Matrix3x4 result) |
Multiplies two instances. More... | |
static Matrix3x4 | Mult (Matrix3x4 left, float right) |
Multiplies an instance by a scalar. More... | |
static void | Mult (ref Matrix3x4 left, float right, out Matrix3x4 result) |
Multiplies an instance by a scalar. More... | |
static Matrix3x4 | Add (Matrix3x4 left, Matrix3x4 right) |
Adds two instances. More... | |
static void | Add (ref Matrix3x4 left, ref Matrix3x4 right, out Matrix3x4 result) |
Adds two instances. More... | |
static Matrix3x4 | Subtract (Matrix3x4 left, Matrix3x4 right) |
Subtracts one instance from another. More... | |
static void | Subtract (ref Matrix3x4 left, ref Matrix3x4 right, out Matrix3x4 result) |
Subtracts one instance from another. More... | |
static Matrix3x4 | Invert (Matrix3x4 mat) |
Calculate the inverse of the given matrix More... | |
static void | Invert (ref Matrix3x4 mat, out Matrix3x4 result) |
Calculate the inverse of the given matrix More... | |
static Matrix4x3 | Transpose (Matrix3x4 mat) |
Calculate the transpose of the given matrix More... | |
static void | Transpose (ref Matrix3x4 mat, out Matrix4x3 result) |
Calculate the transpose of the given matrix More... | |
static Matrix3 | operator* (Matrix3x4 left, Matrix4x3 right) |
Matrix multiplication More... | |
static Matrix3x4 | operator* (Matrix3x4 left, Matrix3x4 right) |
Matrix-scalar multiplication More... | |
static Matrix3x4 | operator* (Matrix3x4 left, float right) |
Matrix-scalar multiplication More... | |
static Matrix3x4 | operator+ (Matrix3x4 left, Matrix3x4 right) |
Matrix addition More... | |
static Matrix3x4 | operator- (Matrix3x4 left, Matrix3x4 right) |
Matrix subtraction More... | |
static bool | operator== (Matrix3x4 left, Matrix3x4 right) |
Compares two instances for equality. More... | |
static bool | operator!= (Matrix3x4 left, Matrix3x4 right) |
Compares two instances for inequality. More... | |
Public Attributes | |
Vector4 | Row0 |
Top row of the matrix More... | |
Vector4 | Row1 |
2nd row of the matrix More... | |
Vector4 | Row2 |
Bottom row of the matrix More... | |
Static Public Attributes | |
static Matrix3x4 | Zero = new Matrix3x4(Vector4.Zero, Vector4.Zero, Vector4.Zero) |
The zero matrix More... | |
Properties | |
Vector3 | Column0 [get] |
Gets the first column of this matrix. More... | |
Vector3 | Column1 [get] |
Gets the second column of this matrix. More... | |
Vector3 | Column2 [get] |
Gets the third column of this matrix. More... | |
Vector3 | Column3 [get] |
Gets the fourth column of this matrix. More... | |
float | M11 [get, set] |
Gets or sets the value at row 1, column 1 of this instance. More... | |
float | M12 [get, set] |
Gets or sets the value at row 1, column 2 of this instance. More... | |
float | M13 [get, set] |
Gets or sets the value at row 1, column 3 of this instance. More... | |
float | M14 [get, set] |
Gets or sets the value at row 1, column 4 of this instance. More... | |
float | M21 [get, set] |
Gets or sets the value at row 2, column 1 of this instance. More... | |
float | M22 [get, set] |
Gets or sets the value at row 2, column 2 of this instance. More... | |
float | M23 [get, set] |
Gets or sets the value at row 2, column 3 of this instance. More... | |
float | M24 [get, set] |
Gets or sets the value at row 2, column 4 of this instance. More... | |
float | M31 [get, set] |
Gets or sets the value at row 3, column 1 of this instance. More... | |
float | M32 [get, set] |
Gets or sets the value at row 3, column 2 of this instance. More... | |
float | M33 [get, set] |
Gets or sets the value at row 3, column 3 of this instance. More... | |
float | M34 [get, set] |
Gets or sets the value at row 3, column 4 of this instance. More... | |
Vector3 | Diagonal [get, set] |
Gets or sets the values along the main diagonal of the matrix. More... | |
float | Trace [get] |
Gets the trace of the matrix, the sum of the values along the diagonal. More... | |
float | this[int rowIndex, int columnIndex] [get, set] |
Gets or sets the value at a specified row and column. More... | |
Represents a 3x4 Matrix
Constructs a new instance.
row0 | Top row of the matrix |
row1 | Second row of the matrix |
row2 | Bottom row of the matrix |
OpenTK.Matrix3x4.Matrix3x4 | ( | float | m00, |
float | m01, | ||
float | m02, | ||
float | m03, | ||
float | m10, | ||
float | m11, | ||
float | m12, | ||
float | m13, | ||
float | m20, | ||
float | m21, | ||
float | m22, | ||
float | m23 | ||
) |
Constructs a new instance.
m00 | First item of the first row of the matrix. |
m01 | Second item of the first row of the matrix. |
m02 | Third item of the first row of the matrix. |
m03 | Fourth item of the first row of the matrix. |
m10 | First item of the second row of the matrix. |
m11 | Second item of the second row of the matrix. |
m12 | Third item of the second row of the matrix. |
m13 | Fourth item of the second row of the matrix. |
m20 | First item of the third row of the matrix. |
m21 | Second item of the third row of the matrix. |
m22 | Third item of the third row of the matrix. |
m23 | First item of the third row of the matrix. |
Adds two instances.
left | The left operand of the addition. |
right | The right operand of the addition. |
|
static |
Adds two instances.
left | The left operand of the addition. |
right | The right operand of the addition. |
result | A new instance that is the result of the addition. |
|
static |
Build a rotation matrix from the specified axis/angle rotation.
axis | The axis to rotate about. |
angle | Angle in radians to rotate counter-clockwise (looking in the direction of the given axis). |
result | A matrix instance. |
Build a rotation matrix from the specified axis/angle rotation.
axis | The axis to rotate about. |
angle | Angle in radians to rotate counter-clockwise (looking in the direction of the given axis). |
|
static |
Builds a rotation matrix from a quaternion.
q | The quaternion to rotate by. |
result | A matrix instance. |
|
static |
Builds a rotation matrix from a quaternion.
q | The quaternion to rotate by. |
|
static |
Builds a rotation matrix for a rotation around the x-axis.
angle | The counter-clockwise angle in radians. |
result | The resulting Matrix4 instance. |
|
static |
Builds a rotation matrix for a rotation around the x-axis.
angle | The counter-clockwise angle in radians. |
|
static |
Builds a rotation matrix for a rotation around the y-axis.
angle | The counter-clockwise angle in radians. |
result | The resulting Matrix4 instance. |
|
static |
Builds a rotation matrix for a rotation around the y-axis.
angle | The counter-clockwise angle in radians. |
|
static |
Builds a rotation matrix for a rotation around the z-axis.
angle | The counter-clockwise angle in radians. |
result | The resulting Matrix4 instance. |
|
static |
Builds a rotation matrix for a rotation around the z-axis.
angle | The counter-clockwise angle in radians. |
|
static |
Build a scaling matrix
scale | Single scale factor for x,y and z axes |
Build a scaling matrix
scale | Scale factors for x,y and z axes |
|
static |
Build a scaling matrix
x | Scale factor for x-axis |
y | Scale factor for y-axis |
z | Scale factor for z-axis |
|
static |
Creates a translation matrix.
x | X translation. |
y | Y translation. |
z | Z translation. |
result | The resulting Matrix4 instance. |
Creates a translation matrix.
vector | The translation vector. |
result | The resulting Matrix4 instance. |
|
static |
Creates a translation matrix.
x | X translation. |
y | Y translation. |
z | Z translation. |
Creates a translation matrix.
vector | The translation vector. |
override bool OpenTK.Matrix3x4.Equals | ( | object | obj | ) |
Indicates whether this instance and a specified object are equal.
obj | The object to compare to. |
bool OpenTK.Matrix3x4.Equals | ( | Matrix3x4 | other | ) |
Indicates whether the current matrix is equal to another matrix.
other | An matrix to compare with this matrix. |
override int OpenTK.Matrix3x4.GetHashCode | ( | ) |
Returns the hashcode for this instance.
void OpenTK.Matrix3x4.Invert | ( | ) |
Converts this instance into its inverse.
Calculate the inverse of the given matrix
mat | The matrix to invert |
InvalidOperationException | Thrown if the Matrix4 is singular. |
Calculate the inverse of the given matrix
mat | The matrix to invert |
result | The inverse of the given matrix if it has one, or the input if it is singular |
InvalidOperationException | Thrown if the Matrix4 is singular. |
Multiplies two instances.
left | The left operand of the multiplication. |
right | The right operand of the multiplication. |
|
static |
Multiplies two instances.
left | The left operand of the multiplication. |
right | The right operand of the multiplication. |
result | A new instance that is the result of the multiplication |
Multiplies two instances.
left | The left operand of the multiplication. |
right | The right operand of the multiplication. |
|
static |
Multiplies two instances.
left | The left operand of the multiplication. |
right | The right operand of the multiplication. |
result | A new instance that is the result of the multiplication |
Multiplies an instance by a scalar.
left | The left operand of the multiplication. |
right | The right operand of the multiplication. |
Multiplies an instance by a scalar.
left | The left operand of the multiplication. |
right | The right operand of the multiplication. |
result | A new instance that is the result of the multiplication |
Compares two instances for inequality.
left | The first instance. |
right | The second instance. |
Matrix multiplication
left | left-hand operand |
right | right-hand operand |
Matrix-scalar multiplication
left | left-hand operand |
right | right-hand operand |
Matrix-scalar multiplication
left | left-hand operand |
right | right-hand operand |
Matrix addition
left | left-hand operand |
right | right-hand operand |
Matrix subtraction
left | left-hand operand |
right | right-hand operand |
Compares two instances for equality.
left | The first instance. |
right | The second instance. |
Subtracts one instance from another.
left | The left operand of the subraction. |
right | The right operand of the subraction. |
|
static |
Subtracts one instance from another.
left | The left operand of the subraction. |
right | The right operand of the subraction. |
result | A new instance that is the result of the subraction. |
override string OpenTK.Matrix3x4.ToString | ( | ) |
Returns a System.String that represents the current Matrix4.
Calculate the transpose of the given matrix
mat | The matrix to transpose |
Calculate the transpose of the given matrix
mat | The matrix to transpose |
result | The result of the calculation |
Vector4 OpenTK.Matrix3x4.Row0 |
Top row of the matrix
Vector4 OpenTK.Matrix3x4.Row1 |
2nd row of the matrix
Vector4 OpenTK.Matrix3x4.Row2 |
Bottom row of the matrix
The zero matrix
|
get |
Gets the first column of this matrix.
|
get |
Gets the second column of this matrix.
|
get |
Gets the third column of this matrix.
|
get |
Gets the fourth column of this matrix.
|
getset |
Gets or sets the values along the main diagonal of the matrix.
|
getset |
Gets or sets the value at row 1, column 1 of this instance.
|
getset |
Gets or sets the value at row 1, column 2 of this instance.
|
getset |
Gets or sets the value at row 1, column 3 of this instance.
|
getset |
Gets or sets the value at row 1, column 4 of this instance.
|
getset |
Gets or sets the value at row 2, column 1 of this instance.
|
getset |
Gets or sets the value at row 2, column 2 of this instance.
|
getset |
Gets or sets the value at row 2, column 3 of this instance.
|
getset |
Gets or sets the value at row 2, column 4 of this instance.
|
getset |
Gets or sets the value at row 3, column 1 of this instance.
|
getset |
Gets or sets the value at row 3, column 2 of this instance.
|
getset |
Gets or sets the value at row 3, column 3 of this instance.
|
getset |
Gets or sets the value at row 3, column 4 of this instance.
|
getset |
Gets or sets the value at a specified row and column.
|
get |
Gets the trace of the matrix, the sum of the values along the diagonal.