adaptiveThresholdAsync function

Future<Mat> adaptiveThresholdAsync(
  1. InputArray src,
  2. double maxValue,
  3. int adaptiveMethod,
  4. int thresholdType,
  5. int blockSize,
  6. double C, {
  7. OutputArray? dst,
})

AdaptiveThreshold applies a fixed-level threshold to each array element.

For further details, please see: https:///docs.opencv.org/master/d7/d1b/group__imgproc__misc.html#ga72b913f352e4a1b1b397736707afcde3

Implementation

Future<Mat> adaptiveThresholdAsync(
  InputArray src,
  double maxValue,
  int adaptiveMethod,
  int thresholdType,
  int blockSize,
  double C, {
  OutputArray? dst,
}) {
  dst ??= Mat.empty();
  return cvRunAsync0(
    (callback) => cimgproc.cv_adaptiveThreshold(
      src.ref,
      dst!.ref,
      maxValue,
      adaptiveMethod,
      thresholdType,
      blockSize,
      C,
      callback,
    ),
    (c) {
      return c.complete(dst);
    },
  );
}