minMaxIdx function
MinMaxIdx finds the global minimum and maximum in an array.
For further details, please see: https://docs.opencv.org/master/d2/de8/group__core__array.html#ga7622c466c628a75d9ed008b42250a73f
Implementation
(double minVal, double maxVal, int minIdx, int maxIdx) minMaxIdx(
InputArray src, {
InputArray? mask,
}) {
return using<(double, double, int, int)>((arena) {
final minValP = arena<ffi.Double>();
final maxValP = arena<ffi.Double>();
final minIdxP = arena<ffi.Int>();
final maxIdxP = arena<ffi.Int>();
cvRun(() => ccore.Mat_MinMaxIdx(src.ref, minValP, maxValP, minIdxP, maxIdxP));
return (minValP.value, maxValP.value, minIdxP.value, maxIdxP.value);
});
}