Open dr-jts opened 6 years ago
2: extra triangles are quite easily caught by breaking sum(area(delaunay_triangles(geom))) = area(convexhull(geom))
A test based on total area should detect most errors, certainly. However, it might not flag very small extra triangles though. And it doesn't pinpoint where the error is.
A brute force test is to check every pair of triangles using the overlaps
predicate.
See #311 for a sketch of an adaptive inCircle function
Issue #298 highlights the robustness limitations of the IncrementalDelaunayTriangulator. While there is a heuristic to avoid this issues (using a distance tolerance) it does impose a potentially unwanted constraint. Some work has been done towards improving the robustness of the Delaunay algorithm (in particular, implementation of a robust
inCircle
predicate usingDD
precision).Here's a roadmap to making the robust DT capability available in production:
IncrementalDelaunayTriangulator
to allow using a robustinCircle
predicate (i.e.inCircleDDFast
)inCircleDDFast
. If not too bad then make it the default (and keep option to use FP inCircle if performance is needed).