getRectSubPix function

Mat getRectSubPix(
  1. InputArray image,
  2. (int, int) patchSize,
  3. Point2f center, {
  4. OutputArray? patch,
  5. int patchType = -1,
})

GetRectSubPix retrieves a pixel rectangle from an image with sub-pixel accuracy.

For further details, please see: https:///docs.opencv.org/master/da/d54/group__imgproc__transform.html#ga77576d06075c1a4b6ba1a608850cd614

Implementation

Mat getRectSubPix(
  InputArray image,
  (int, int) patchSize,
  Point2f center, {
  OutputArray? patch,
  int patchType = -1,
}) {
  patch ??= Mat.empty();
  cvRun(() => cimgproc.GetRectSubPix(image.ref, patchSize.cvd.ref, center.ref, patch!.ref));
  return patch;
}