estimatePoseCharucoBoardAsync function

Future<(bool, Mat, Mat)> estimatePoseCharucoBoardAsync(
  1. VecPoint2f charucoCorners,
  2. VecI32 charucoIds,
  3. CharucoBoard board,
  4. InputArray cameraMatrix,
  5. InputArray distCoeffs, {
  6. Mat? rvec,
  7. Mat? tvec,
  8. bool useExtrinsicGuess = false,
})

Implementation

Future<(bool rval, Mat rvec, Mat tvec)> estimatePoseCharucoBoardAsync(
  VecPoint2f charucoCorners,
  VecI32 charucoIds,
  CharucoBoard board,
  InputArray cameraMatrix,
  InputArray distCoeffs, {
  Mat? rvec,
  Mat? tvec,
  bool useExtrinsicGuess = false,
}) async {
  rvec ??= Mat.empty();
  tvec ??= Mat.empty();
  final pb = calloc<ffi.Bool>();
  return cvRunAsync0(
    (callback) => ccontrib.cv_aruco_estimatePoseCharucoBoard(
      charucoCorners.ref,
      charucoIds.ref,
      board.ref,
      cameraMatrix.ref,
      distCoeffs.ref,
      rvec!.ref,
      tvec!.ref,
      useExtrinsicGuess,
      pb,
      callback,
    ),
    (c) {
      final rval = pb.value;
      calloc.free(pb);
      c.complete((rval, rvec!, tvec!));
    },
  );
}