public static cvPointPolygonTest ( IntPtr contour, PointF pt, bool measureDist ) : double | ||
contour | IntPtr | Input contour |
pt | PointF | The point tested against the contour |
measureDist | bool | If true, the function estimates distance from the point to the nearest contour edge |
return | double |
public static double cvPointPolygonTest(
IntPtr contour,
PointF pt,
bool measureDist)
{
return cvPointPolygonTest(contour, pt, measureDist ? 1 : 0);
}
CvInvoke::cvPointPolygonTest ( IntPtr contour, PointF pt, int measureDist ) : double |
/// <summary> /// Determines the distance from the point to the contour /// </summary> /// <param name="point">The point to measured distance</param> /// <returns>positive distance if inside; negative distance if outside; 0 if on the contour</returns> public double Distance(PointF point) { return(CvInvoke.cvPointPolygonTest(Ptr, point, 1)); }