alignCrop method

Mat alignCrop(
  1. Mat srcImg,
  2. Mat faceBox
)

Aligns detected face with the source input image and crops it.

srcImg input image faceBox the detected face result from the input image

https://docs.opencv.org/4.x/da/d09/classcv_1_1FaceRecognizerSF.html#a84492908abecbc9362b4ddc8d46b8345

Implementation

Mat alignCrop(Mat srcImg, Mat faceBox) {
  final p = calloc<cobjdetect.Mat>();
  cvRun(() => cobjdetect.FaceRecognizerSF_AlignCrop(ref, srcImg.ref, faceBox.ref, p));
  return Mat.fromPointer(p);
}