case class DelaunayTriangulation(pointSet: CompleteIndexedPointSet, halfEdgeTable: HalfEdgeTable, tolerance: Double, debug: Boolean) extends Product with Serializable
Generates the Delaunay triangulation of a set of points.
The DelaunayTriangulation class operates on a collection of Coordinates to produce the unique triangulation (after projecting the points to the x-y plane) that satisfies the condition of each triangle in the result having a circumscribing circle where no vertices of the input point set are in the interior of that circle.
Note that the input set must have 2 or more distinct points. Collinear points are allowed.
Whenever using this class for complex tasks with large quantities of points, numerical issues must be considered. First, this triangulator will pare down the input set so as to remove points which are not numerically distinct. This may result in points which are not strictly equal, but indistinguishable from one another with respect to the geometric predicates (collinearity tests, in-circle tests, orientation tests). Failure to understand and address potential numerical issues in your data *may cause infinite loops*! (It is our experience that sufficiently large point sets will eventually run afoul of these problems if left alone.) The /tolerance/ parameter is set to a reasonable value in the defaults of the DelaunayTriangulation object's apply() method, but bear in mind that problems may arise in your particular case.
- Alphabetic
- By Inheritance
- DelaunayTriangulation
- Serializable
- Serializable
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new DelaunayTriangulation(pointSet: CompleteIndexedPointSet, halfEdgeTable: HalfEdgeTable, tolerance: Double, debug: Boolean)
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
boundary(): Int
Returns a reference to the half edge on the outside of the boundary of the triangulation.
Returns a reference to the half edge on the outside of the boundary of the triangulation.
Starting from this half edge, the boundary of the triangulation can be traversed. This exterior loop will have a clockwise winding and will be convex.
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- val debug: Boolean
-
def
decimate(nRemove: Int): Unit
Simplifies a triangulation.
Simplifies a triangulation.
This method will remove a specified number of vertices from the triangulation, where the next vertex to be removed causes the least amount of error to be introduced to the surface. This function assumes that all coordinates have a valid z component, and therefore, the triangulation is interpretable as a height field.
Implementation is based on paper by Garland, Michael, and Paul S. Heckbert. "Surface simplification using quadric error metrics." Proceedings of the 24th annual conference on Computer graphics and interactive techniques. ACM Press/Addison-Wesley Publishing Co., 1997.
-
def
deletePoint(vi: Int): Unit
A function to remove a vertex from a DelaunayTriangulation that preserves the Delaunay property for all newly created fill triangles.
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- val halfEdgeTable: HalfEdgeTable
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
isLinear(): Boolean
Is this triangulation linear?
Is this triangulation linear?
If all distinct input points are collinear, this will return true. If so, the triangleMap will be empty.
-
def
isMeshValid(): Boolean
A correctness check for the triangulation.
A correctness check for the triangulation.
Ensures that the mesh is correctly built with no obvious topological errors in the mesh.
-
def
isUnfolded(bound: Int, lo: Int, hi: Int): Boolean
A version of isUnfolded that is useful for testing subregions of a triangulation.
A version of isUnfolded that is useful for testing subregions of a triangulation.
If during construction, a triangulation has smaller regions with their own bounding loops involving only vertex indices in a certain range, one may provide a reference to a bounding edge and the lo and hi indices in the range, and perform the isUnfolded test on that subregion.
-
def
isUnfolded(): Boolean
A correctness check which tests if two triangles which share an edge overlapping.
- def liveVertices: Set[Int]
-
def
navigate(): Unit
Provides a text-based interactive interface to explore the structure of a triangulation.
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def numVertices: Int
- val pointSet: CompleteIndexedPointSet
- val predicates: TriangulationPredicates
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
- val tolerance: Double
-
val
triangleMap: TriangleMap
Contains the triangles of a DelaunayTriangulation
Contains the triangles of a DelaunayTriangulation
Note: This collection will be empty if isLinear is true.
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
writeWKT(wktFile: String): PrintWriter
Outputs the triangulation to the named file as a WKT representation of a MultiPolygon.