detectAsync method

Future<(VecPoint, VecPoint)> detectAsync(
  1. InputArray img, {
  2. double hitThreshold = 0,
  3. (int, int) winStride = (0, 0),
  4. (int, int) padding = (0, 0),
})

Implementation

Future<(VecPoint foundLocations, VecPoint searchLocations)> detectAsync(
  InputArray img, {
  double hitThreshold = 0,
  (int, int) winStride = (0, 0),
  (int, int) padding = (0, 0),
}) async {
  final rval = cvRunAsync2<(VecPoint, VecPoint)>(
      (callback) => cobjdetect.HOGDescriptor_Detect2_Async(
            ref,
            img.ref,
            hitThreshold,
            winStride.cvd.ref,
            padding.cvd.ref,
            callback,
          ), (c, foundLocations, searchLocations) {
    return c.complete(
      (
        VecPoint.fromPointer(foundLocations.cast<cvg.VecPoint>()),
        VecPoint.fromPointer(searchLocations.cast<cvg.VecPoint>())
      ),
    );
  });
  return rval;
}