Matrix
Constructors
Properties
Methods
Constructors
Properties
- Matrix.m
- Type
SC.Matrix16
Methods
assign
copy
equals
equalsWithTolerance
- Matrix.equalsWithTolerance(other, tolerance)
Compares this matrix with another using a tolerance.
- Arguments
other (
Matrix()
) – Matrix to compare with.tolerance (
number()
) – Tolerance to be used in the comparison.
- Return type
boolean
- Returns
True if the values of this matrix equal those of the other.
forJson
- Matrix.forJson()
- Deprecated
Use
toJson
instead.- Return type
Object
inverseAndDeterminant
isIdentity
- Matrix.isIdentity()
- Return type
boolean
loadIdentity
multiplyByScalar
normalMatrix
scale
setScaleComponent
setTranslationComponent
toJson
- Matrix.toJson()
Creates an object ready for JSON serialization.
- Return type
[number]
- Returns
The prepared object.
transform
- Matrix.transform(point, result)
Transforms a point according to this matrix. The source and destination points are allowed to be the same object.
transform4
- Matrix.transform4(point, result)
Transforms a point according to this matrix. The source and destination points are allowed to be the same object.
transformArray
- Matrix.transformArray(inPoints, outPoints)
Transforms an array of points according to this matrix.
transformBox
transpose
upperLeft3x3Determinant
- Matrix.upperLeft3x3Determinant()
Computes the determinant of the upper-left 3x3 subsection of this matrix.
- Return type
number
static construct
static createFromArray
static createFromBasis
static createFromOffAxisRotation
- Matrix.createFromOffAxisRotation(axis, degrees)
Creates a rotation matrix from an arbitrary axis.
static fromJson
static inverse
static multiply
- Matrix.multiply(m1, m2)
Multiplies two matrices.
(p’ = ABp <=> p’ = multiply(B, A).transform(p))
- Arguments
- Return type
- Returns
Matrix which is the result of the multiplication.
(p’ = ABp <=> p’ = multiply(B, A).transform(p))