getTransformation method

AffineTransformation? getTransformation()

Computes the {@link AffineTransformation} determined by the control point mappings, or null if the control vectors do not determine a well-defined transformation.

@return an affine transformation, or null if the control vectors do not determine a well-defined transformation

Implementation

AffineTransformation? getTransformation() {
  // compute full 3-point transformation
  bool isSolvable = compute();
  if (isSolvable)
    return AffineTransformation.fromMatrixValues(
        m00, m01, m02, m10, m11, m12);
  return null;
}