mapXY method

Point mapXY(
  1. double x,
  2. double y
)

Returns Point (x, y) multiplied by Matrix. Given:

         | A B C |        | x |
Matrix = | D E F |,  pt = | y |
         | G H I |        | 1 |

result is computed as:

              |A B C| |x|                               Ax+By+C   Dx+Ey+F
Matrix * pt = |D E F| |y| = |Ax+By+C Dx+Ey+F Gx+Hy+I| = ------- , -------
              |G H I| |1|                               Gx+Hy+I   Gx+Hy+I

@param x x-axis value of Point to map @param y y-axis value of Point to map @return mapped Point

Implementation

Point mapXY(double x, double y) {
  final px = calloc<ffi.Float>();
  final py = calloc<ffi.Float>();
  c.mnn_cv_matrix_map_xy(ptr, x, y, px, py);
  final result = Point.fromXY(px.value, py.value);
  calloc.free(px);
  calloc.free(py);
  return result;
}