Mat3D
Description
A 3x3 matrix with 64-bit floating-point precision.
/ \ | M11 M12 M13 | | M21 M22 M23 | | M31 M32 M33 | \ /
Public / Constructors
Rotate
2 overloads
Returns a rotation matrix (counter-clockwise around the given axis for right-handed coordinate system).
Returns a rotation matrix (counter-clockwise around the given axis for right-handed coordinate system).
RotateX
Returns a rotation matrix (counter-clockwise around X-axis for right-handed coordinate system).
RotateY
Returns a rotation matrix (counter-clockwise around Y-axis for right-handed coordinate system).
RotateZ
Returns a rotation matrix (counter-clockwise around Z-axis for right-handed coordinate system).
Translate
2 overloads
Returns a homogeneous 2D translation matrix.
Returns a homogeneous 2D translation matrix.
Warp
Computes a 2D homogeneous warp matrix that transforms the unit square into a convex quadrilateral.
The unit square is defined as follows:
A ---- B A := (0|0) | | B := (1|0) | | C := (1|1) D ---- C D := (0|1)
Use the inverse warp matrix to transform vertices to the unit square. Combine two warp matrices to transform from one quadrilateral to another.
Public / Methods
Mul2
3 overloads
Multiplies this matrix (left-side) with the given homogeneous 2D vector (right-side): result = this * v
.
Multiplies this matrix (left-side) with the given homogeneous 2D vector (right-side): result = this * v
.
Multiplies this matrix (left-side) with the given 2D point (right-side), assuming a homogeneous W-coordinate of 1 and computes the partial derivatives: result = this * v
.
Mul3
2 overloads
Multiplies this matrix (left-side) with the given vector (right-side): result = this * v
.
Multiplies this matrix (left-side) with the given vector (right-side): result = this * v
.
ToArray
Copies matrix elements to the given array.
The method uses the following indexing scheme to write values to values in:
values[offset + (row - 1) * strideRow + (col - 1) * strideCol := matrix[row, col];
where row
and col
depict the matrix row and column number (starting at 1
).
ToString
2 overloads
Returns the string representation of this matrix.
The Mat3D.ToString1 method uses FormatFlags.Precision15.
- See also