Closed GoogleCodeExporter closed 8 years ago
If possible try to round your input to a precision that you can live with and
not have individual points just differentiate in the 16th decimal. You will be
bound to run into some floating point issues.
poly2tri should under no circumstances alter the values of any points.
poly2tri do add 2 points to the pointset it tries to triangulate so it can
start of with a triangle. These are removed when finished tho.
A longshot guess is that the triangulation fails due to some precision issue
and that you might be looking at some defect result. Still can't understand why
two points are missing.
Original comment by thahlen@gmail.com
on 8 Oct 2012 at 4:12
I tried upscaling the input with no effect.
Original comment by dusan.ma...@gmail.com
on 8 Oct 2012 at 5:04
On closer inspection that point set will not work on any on the poly2tri
version since it's not a simple polygon.
It has crossing edges and the shape is more like an 8. Swap the first two
points and you get a simple polygon and the triangulation should work.
poly2tri has no input validation and assumes you feed it simple polygons.
Original comment by thahlen@gmail.com
on 9 Oct 2012 at 12:06
Original issue reported on code.google.com by
dusan.ma...@gmail.com
on 8 Oct 2012 at 10:59