warpPerspective function

VARP warpPerspective(
  1. VARP src,
  2. Matrix M,
  3. (int, int) dsize, {
  4. int flags = INTER_LINEAR,
  5. int borderMode = BORDER_CONSTANT,
  6. int borderValue = 0,
})

Implementation

VARP warpPerspective(
  VARP src,
  Matrix M,
  (int, int) dsize, {
  int flags = INTER_LINEAR,
  int borderMode = BORDER_CONSTANT,
  int borderValue = 0,
}) {
  final cDsize = Size.fromTuple(dsize);
  final pOut = c.mnn_cv_warpPerspective(
    src.ptr,
    M.ptr,
    cDsize.ref,
    flags,
    borderMode,
    borderValue,
  );
  final rval = VARP.fromPointer(pOut);
  cDsize.dispose();
  return rval;
}