Point FindPointInPolygon(List<Vertex> contour)

Dec 17, 2015 at 12:12 PM

I need to increase the limit from 8 to 10 in with my polygons inside this function. It would be great to add a small description on how this method finds a point in a polygon and why you may need to increase the limit = 8 threshold.


Dec 17, 2015 at 12:37 PM
Edited Dec 17, 2015 at 1:44 PM
See https://triangle.codeplex.com/discussions/542075

EDIT: Actually, the way it is implemented now, the algorithm can easily be defeated:
int limit = 8;
double h = 1.0 / limit;

var contour = new List<Vertex>() {
    new Vertex(0, 0), new Vertex(1, 0), new Vertex(h, h), new Vertex(0, 1)

    Contour.FindPointInPolygon(contour, limit);
The algorithm described in the above link (searching at a convex corner) might be a better option.
Dec 17, 2015 at 12:38 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.