AffineMatrix class
An immutable affine matrix, a 3x3 column-major-order matrix in which the
last row is always set to the identity values, i.e. 0 0 1
.
- Annotations
-
- @immutable
Constructors
Properties
- a → double
-
The 0,0 position of the matrix.
final
- b → double
-
The 0,1 position of the matrix.
final
- c → double
-
The 1,0 position of the matrix.
final
- d → double
-
The 1,1 position of the matrix.
final
- e → double
-
The 2,0 position of the matrix.
final
- encodableInRect → bool
-
Whether this matrix can be expressed be applied to a rect without any loss
of inforamtion.
no setter
- f → double
-
The 1,2 position of the matrix.
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
multiplied(
AffineMatrix other) → AffineMatrix -
Creates a new affine matrix of this concatenated with
other
. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
rotated(
double radians) → AffineMatrix -
Creates a new affine matrix rotated by
radians
. -
scaled(
double x, [double? y]) → AffineMatrix -
Creates a new affine matrix rotated by
x
andy
. -
scaleStrokeWidth(
double? width) → double? - Calculates the scale for a stroke width based on the average of the x- and y-axis scales of this matrix.
-
toMatrix4(
) → Float64List -
Creates a typed data representatino of this matrix suitable for use with
package:vector_math_64
(and, by extension, Flutter/dart:ui). -
toString(
) → String -
A string representation of this object.
override
-
transformPoint(
Point point) → Point -
Maps
point
using the values of this matrix. -
transformRect(
Rect rect) → Rect -
Maps
rect
using the values of this matrix. -
translated(
double x, double y) → AffineMatrix - Creates a new affine matrix, translated along the x and y axis.
-
xSkewed(
double x) → AffineMatrix - Creates a new affine matrix, skewed along the x axis.
-
ySkewed(
double y) → AffineMatrix - Creates a new affine matrix, skewed along the y axis.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Constants
- identity → const AffineMatrix
- The identity affine matrix.