invertAsync function
Invert finds the inverse or pseudo-inverse of a matrix.
For further details, please see: https://docs.opencv.org/master/d2/de8/group__core__array.html#gad278044679d4ecf20f7622cc151aaaa2
Implementation
Future<(double rval, Mat dst)> invertAsync(
InputArray src, {
OutputArray? dst,
int flags = DECOMP_LU,
}) async {
dst ??= Mat.empty();
final p = calloc<ffi.Double>();
return cvRunAsync0(
(callback) => ccore.cv_invert(src.ref, dst!.ref, flags, p, callback),
(c) {
final rval = p.value;
calloc.free(p);
return c.complete((rval, dst!));
},
);
}