Closed preet closed 11 years ago
Hi Preet,
This should work without problems. As you write, the repair() function sets interior triangles to NULL after reconstruction.
However, if speed is an issue, you might consider extracting the triangulation in the repair() function itself, after tagging and before reconstruction. In that case, you should use the triangles marked with the interior tag.
Cheers, Ken
Hi! I'd been using prepair before to fix land polygons so that I could subsequently triangulate and then render them in 3d. However, since prepair uses triangulation as a basis to fix degenerate polygons, I've been trying to extract the relevant triangulation directly.
I do this by looking at the value of the additional 'info()' param that's attached to each triangulation face and compare the value to the 'interior' and 'exterior' addresses defined in the repair() function. I opt to keep triangles that have an info() == NULL because it seems like the repair() function sets all interior faces to NULL after processing them whereas exterior faces will have a non null address.
The result seems to work, but I'm not sure if what I'm doing is correct. Will interior triangles always correspond to NULL? Am I collecting the right set of triangles by doing the following?:
Regards,
Preet