public class Triangulator extends Object
Coordinates are not created, modified, or discarded. Thus, the triangles created will be composed of the Coordinates passed in to the Triangulator. See White, Marvin S., Jr. and Griffin, Patricia. 1985. Piecewise linear rubber-sheet map transformation. "The American Cartographer" 12:2, 123-31.
| Constructor and Description |
|---|
Triangulator() |
| Modifier and Type | Method and Description |
|---|---|
protected com.vividsolutions.jts.geom.Coordinate |
add(com.vividsolutions.jts.geom.Coordinate a,
com.vividsolutions.jts.geom.LineString vector) |
protected List |
alternativeTriangles(Triangle PQS,
Triangle QRS) |
Collection |
getIgnoredVectors()
Permits the caller to identify which vectors were ignored because they
were not 2-point LineStrings
|
protected List |
heightMaximizedTriangles(Triangle PQS,
Triangle QRS)
The intent of this method is to avoid narrow triangles, which create near
singularities.
|
static Collection |
nonVectors(Collection geometries) |
protected Quadrilateral |
tag(Quadrilateral sourceQuad,
Quadrilateral destQuad) |
static List |
taggedVectorVertices(boolean tips,
Collection vectors)
The returned Coordinates will be tagged with the tails if the tips are
requested (or the tips, if the tails are requested).
|
protected Triangle |
triangleContaining(com.vividsolutions.jts.geom.Coordinate p,
List triangles) |
Map |
triangleMap(com.vividsolutions.jts.geom.Envelope datasetEnvelope,
Collection vectorLineStrings,
Collection sourceHints,
Collection destinationHints,
TaskMonitor monitor) |
Map |
triangleMap(com.vividsolutions.jts.geom.Envelope datasetEnvelope,
Collection vectorLineStrings,
TaskMonitor monitor)
Splits two regions into Triangles.
|
static boolean |
vector(com.vividsolutions.jts.geom.Geometry g) |
protected com.vividsolutions.jts.geom.LineString |
vectorWithNearestTail(com.vividsolutions.jts.geom.Coordinate x,
List vectors) |
public Map triangleMap(com.vividsolutions.jts.geom.Envelope datasetEnvelope, Collection vectorLineStrings, TaskMonitor monitor)
datasetEnvelope - the region to triangulatevectors - vectors (2-point LineStrings) whose tails and tips split
the "source quadrilateral" and "destination quadrilateral" into trianglespublic Map triangleMap(com.vividsolutions.jts.geom.Envelope datasetEnvelope, Collection vectorLineStrings, Collection sourceHints, Collection destinationHints, TaskMonitor monitor)
sourceHints - "far-away" Coordinates (even outside the dataset envelope) for which
we must ensure that source triangles include.destinationHints - "far-away" Coordinates for which we must ensure that destination
triangles includepublic Collection getIgnoredVectors()
public static Collection nonVectors(Collection geometries)
public static boolean vector(com.vividsolutions.jts.geom.Geometry g)
protected List heightMaximizedTriangles(Triangle PQS, Triangle QRS)
PQS - a triangle sharing an edge with QRS; vertex order is irrelevantprotected Triangle triangleContaining(com.vividsolutions.jts.geom.Coordinate p, List triangles)
protected com.vividsolutions.jts.geom.Coordinate add(com.vividsolutions.jts.geom.Coordinate a,
com.vividsolutions.jts.geom.LineString vector)
protected com.vividsolutions.jts.geom.LineString vectorWithNearestTail(com.vividsolutions.jts.geom.Coordinate x,
List vectors)
protected Quadrilateral tag(Quadrilateral sourceQuad, Quadrilateral destQuad)
protected List alternativeTriangles(Triangle PQS, Triangle QRS)
PQS - a triangle sharing an edge with QRS; vertex order is irrelevantpublic static List taggedVectorVertices(boolean tips, Collection vectors)
tips - true to return the vector tips; otherwise, the tailsCopyright © 2015. All rights reserved.