I found the same problem as above and your description of the problem helped to give me the answer. If the path is closed already, the path.IsVisible(point) should work. To keep the line as pure looking as possible using pixels, just reverse the points in the array and add them to the original set. Then add them to a closed curve in the path. GraphicsPath _curvePath = new GraphicsPath(); List<PointF> closedCurvePoints = new List<PointF>(_curvePoints); closedCurvePoints.Reverse(); closedCurvePoints.AddRange(_curvePoints); _curvePath.AddClosedCurve(closedCurvePoints.ToArray());
This worked well for me - even for curves that backed in on themselves. Hopefully it will be helpful to someone else if you have no need for this info anymore
A
adelboy
@adelboy
Posts
-
How to decide if a Point is on a curve