Create a 3x3 matrix with the given arguments in row-major order. If no arguments are provided, the constructor initializes the Matrix3 to the 3x3 identity matrix.
Optional
n11: numberInput element in the first row and the first column
Optional
n12: numberInput element in the first row and the second column
Optional
n13: numberInput element in the first row and the third column
Optional
n21: numberInput element in the second row and the first column
Optional
n22: numberInput element in the second row and the second column
Optional
n23: numberInput element in the second row and the third column
Optional
n31: numberInput element in the third row and the first column
Optional
n32: numberInput element in the third row and the second column
Optional
n33: numberInput element in the third row and the third column
A column-major list of matrix values.
Static
IDENTITYIdentity matrix.
Creates a new 3x3 matrix and with identical elements to this one.
Return the cloned matrix
Copy the elements of matrix m into this matrix.
Input one matrix copied from
Return this matrix
Return true if this matrix and m are equal.
Input one matrix to compare
Return true if this matrix and m are equal.
Extracts the basis of this matrix into the three axis vectors provided
Input X axis vector
Input Y axis vector
Input Z axis vector
Return this matrix
Set the elements of this matrix based on an array in column-major format.
Input the array to read the elements from.
Optional
offset: numberInput (optional) index of first element in the array. Default is 0.
Return this matrix
Sets this matrix as the upper left 3x3 of the normal matrix of the passed matrix4. The normal matrix is the inverse transpose of the matrix m.
Input one 4x4 matrix
Return this matrix
Set this matrix as a 2D translation transform:
Input one 2d vector or one number
Input one number
Return this matrix
Post-multiplies this matrix by m.
Input one 3x3 matrix
Return this matrix
Set this matrix to a x b.
Input one 3x3 matrix
Input one 3x3 matrix
Return this matrix
Pre-multiplies this matrix by m.
Input one 3x3 matrix
Return this matrix
Set the 3x3 matrix values to the given row-major sequence of values.
Input element in the first row and the first column
Input element in the first row and the second column
Input element in the first row and the third column
Input element in the second row and the first column
Input element in the second row and the second column
Input element in the second row and the third column
Input element in the third row and the first column
Input element in the third row and the second column
Input element in the third row and the third column
Return this matrix
Set this matrix to the upper 3x3 matrix of the Matrix4 m.
Input one 4x4 matrix
Return this matrix
Set the UV transform matrix from offset, repeat, rotation, and center.
Input offset x
Input offset y
Input repeat x
Input repeat y
Input rotation, in radians. Positive values rotate counterclockwise
Input center x of rotation
Input center y of rotation
Return this matrix
Write the elements of this matrix to an array in column-major format.
Optional
array: number[]Input (optional) array to store the resulting vector in. If not given a new array will be created.
Optional
offset: numberInput (optional) offset in the array at which to put the result.
Return this matrix
Set this matrix as the upper left 3x3 of the normal matrix of the passed matrix4. The normal matrix is the inverse transpose of the matrix m.
Input one 4x4 matrix
Return this matrix
The class representing a 3x3 matrix.