Expand description
Port of src/ast/transform/utils.ts: matrix operations of the transform functions.
Constants§
- IDENTITY_
MATRIX - the identity matrix
Functions§
- decompose
- decompose a matrix: translate → rotate → skew → scale. false if the matrix cannot be decomposed
- identity
- is_
2d_ matrix - https://drafts.csswg.org/css-transforms-1/#2d-matrix
- is_
identity - true if the values are equal (
===) to the values of the identity matrix - js_
hypot Math.hypot()(v8 algorithm: scaled, compensated sum)- multiply
- multiply_
in_ place matrix = matrix × b- multiply_
into result = a × b(the operands are read before the result is written)- round
- round a number to 6 significant digits, or to the nearest integer when it is closer than
epsilon - set_
identity - to_
precision6 +value.toPrecision(6)- to_zero
- to_
zero_ value - a value close to 0 (
epsilon) is set to 0, the other values are rounded to 6 significant digits