| java.lang.Object com.vividsolutions.jump.warp.Triangulator
Triangulator | public class Triangulator (Code) | | A better name for this class would have been TriangleMapFactory. Given the
coordinates of an initial and final triangulation, it will return a map of source
Triangle to destination Triangle.
Creates a FeatureCollection of triangles covering a given area. Thin
triangles are avoided.
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.
|
Method Summary | |
protected Coordinate | add(Coordinate a, LineString vector) | protected List | alternativeTriangles(Triangle PQS, Triangle QRS) | public Collection | getIgnoredVectors() | protected List | heightMaximizedTriangles(Triangle PQS, Triangle QRS) The intent of this method is to avoid narrow triangles, which create near
singularities. | public static Collection | nonVectors(Collection geometries) | protected Quadrilateral | tag(Quadrilateral sourceQuad, Quadrilateral destQuad) | public 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(Coordinate p, List triangles) | public Map | triangleMap(Envelope datasetEnvelope, Collection vectorLineStrings, TaskMonitor monitor) Splits two regions into Triangles. | public Map | triangleMap(Envelope datasetEnvelope, Collection vectorLineStrings, Collection sourceHints, Collection destinationHints, TaskMonitor monitor) Parameters: sourceHints - "far-away" Coordinates (even outside the dataset envelope) for whichwe must ensure that source triangles include. | public static boolean | vector(Geometry g) | protected LineString | vectorWithNearestTail(Coordinate x, List vectors) |
Triangulator | public Triangulator()(Code) | | |
add | protected Coordinate add(Coordinate a, LineString vector)(Code) | | a + the displacement represented by vector |
alternativeTriangles | protected List alternativeTriangles(Triangle PQS, Triangle QRS)(Code) | | Parameters: PQS - a triangle sharing an edge with QRS; vertex order is irrelevant triangles PQR and PRS, or null if PQRS is not convex |
getIgnoredVectors | public Collection getIgnoredVectors()(Code) | | Permits the caller to identify which vectors were ignored because they
were not 2-point LineStrings
|
heightMaximizedTriangles | protected List heightMaximizedTriangles(Triangle PQS, Triangle QRS)(Code) | | The intent of this method is to avoid narrow triangles, which create near
singularities.
Parameters: PQS - a triangle sharing an edge with QRS; vertex order is irrelevant (PQS and QRS) or (PQR, PRS), whichever pair has the largestminimum height |
taggedVectorVertices | public static List taggedVectorVertices(boolean tips, Collection vectors)(Code) | | The returned Coordinates will be tagged with the tails if the tips are
requested (or the tips, if the tails are requested).
Parameters: tips - true to return the vector tips; otherwise, the tails |
triangleContaining | protected Triangle triangleContaining(Coordinate p, List triangles)(Code) | | the triangle containing p, or null if no triangle contains p |
triangleMap | public Map triangleMap(Envelope datasetEnvelope, Collection vectorLineStrings, TaskMonitor monitor)(Code) | | Splits two regions into Triangles. The two regions are called the
"source quadrilateral" and "destination quadrilateral", and are based on
the given dataset envelope. The "source quadrilateral" is the dataset envelope
expanded 5% along each margin. The "destination quadrilateral" is the
source quadrilateral with each vertex shifted according to the vector with
the nearest tail. The source quadrilateral is split using the vector tails;
the destination quadrilateral is split using the vector tips. In this way,
the vectors map the source Triangles to the destination Triangles.
Parameters: datasetEnvelope - the region to triangulate Parameters: vectorLineStrings - vectors (2-point LineStrings) whose tails and tips splitthe "source quadrilateral" and "destination quadrilateral" into triangles Parameters: monitor - a map of source Triangles to destination Triangles |
triangleMap | public Map triangleMap(Envelope datasetEnvelope, Collection vectorLineStrings, Collection sourceHints, Collection destinationHints, TaskMonitor monitor)(Code) | | Parameters: sourceHints - "far-away" Coordinates (even outside the dataset envelope) for whichwe must ensure that source triangles include. Parameters: destinationHints - "far-away" Coordinates for which we must ensure that destinationtriangles include |
vector | public static boolean vector(Geometry g)(Code) | | |
vectorWithNearestTail | protected LineString vectorWithNearestTail(Coordinate x, List vectors)(Code) | | |
|
|