approxPolyN function
ApproxPolyN approximates a polygon with a convex hull with a specified accuracy and number of sides.
For further details, please see:
https://docs.opencv.org/4.x/d3/dc0/group__imgproc__shape.html#ga88981607a2d61b95074688aac55625cc
Implementation
VecPoint approxPolyN(
VecPoint curve,
int nsides, {
double epsilon_percentage = -1.0,
bool ensure_convex = true,
}) {
final vec = VecPoint();
cvRun(
() => cimgproc.cv_approxPolyN(curve.ref, nsides, epsilon_percentage, ensure_convex, vec.ptr, ffi.nullptr),
);
return vec;
}