An implementation of a matrix that represents an affine transformation and works with Point.
Remarks
The matrix is interpreted row-major. The rows are defined as follows: [ m11 m12 dx ], [ m21 m22 dy ], ([ 0 0 1 ] implicitly).
When transforming a vector v using this matrix, the multiplication is done in this order: v' = M v.
Prepending a matrix T to this instance results in the operation M′ = M T. In concept, this means that T is applied before M when applying M' to a vector. Appending T to M results in M′ = T M.
Type Details
- yfiles module
- view-component
- yfiles-umd modules
- All view modules
- Legacy UMD name
- yfiles.geometry.Matrix
Constructors
Properties
Methods
Create a clone of this object.
Multiplies this matrix instance by the given instance using the given order.
Parameters
A map of options to pass to the method.
- matrix - Matrix
- The matrix to multiply with this one.
- order - MatrixOrder
- The order of the multiplication. PREPEND if not specified.
Prepends or appends a rotation operation to this matrix around the specified rotation center.
Parameters
A map of options to pass to the method.
- theta - number
- The rotation angle in radians
- center - Point
- The coordinate of the center of the rotation.
- order - MatrixOrder
- Whether to append or prepend the rotation matrix.
Prepends or appends a rotation operation to this matrix around the origin.
Parameters
A map of options to pass to the method.
- theta - number
- The rotation angle in radians
- order - MatrixOrder
- Whether to append or prepend the rotation matrix.
Appends or prepends a scale operation to this instance.
Converts the Matrix object to a CSS transform.
Remarks
Returns
- ↪string
- The transform string
Converts the Matrix object to an SVG transform string.
Remarks
Returns
- ↪string
- The transform string
Transforms the given point in place.
Parameters
A map of options to pass to the method.
- point - IMutablePoint
- The point to transform and return.
Returns
- ↪IMutablePoint
point
Appends or Prepends a translation to this instance.
Constants
Gets an unmodifiable identity matrix.
Gets an unmodifiable projection matrix that makes the graph look isometric.