decodeAsync method
Future<(String, VecPoint?, Mat?)>
decodeAsync(
- InputArray img, {
- VecPoint? points,
- Mat? straightCode,
Implementation
Future<(String ret, VecPoint? points, Mat? straightCode)> decodeAsync(
InputArray img, {
VecPoint? points,
Mat? straightCode,
}) {
points ??= VecPoint();
final ret = calloc<ffi.Pointer<ffi.Char>>();
straightCode ??= Mat.empty();
return cvRunAsync0(
(callback) =>
cobjdetect.cv_QRCodeDetector_decode(ref, img.ref, points!.ptr, straightCode!.ref, ret, callback),
(c) {
final info = ret.value.cast<Utf8>().toDartString();
calloc.free(ret);
return c.complete((info, points, straightCode));
},
);
}