Gets the matrix that represents this transformation.
p = object.matrix
The matrix that represents this transformation.
The matrix object is live (that is, any changes to the SVGTransform object are immediately reflected in the matrix object and vice versa). If you change the matrix object directly (that is, without using the SVGTransform methods), the SVGTransform type changes to SVG_TRANSFORM_MATRIX.
The values in the returned matrix changes based on the type of matrix:
- For a SVG_TRANSFORM_MATRIX matrix, the matrix contains the a, b, c, d, e, and f values that the user supplies.
- For a SVG_TRANSFORM_TRANSLATE matrix, the e and f values represent the translation amounts (a=1, b=0, c=0, and d=1).
- For a SVG_TRANSFORM_SCALE matrix, the a and d values represent the translation amounts (b=0, c=0, e=0, and f=0).
- For a SVG_TRANSFORM_ROTATE, SVG_TRANSFORM_SKEWX, or SVG_TRANSFORM_SKEWY matrix, the a, b, c, and d values represent the matrix that causes the given transformation (e=0 and f=0).