net.nexttext.renderer.util
Class DoublyConnectedEdgeList<Vertex extends PlanarVertex,Edge extends PlanarEdge>
java.lang.Object
net.nexttext.renderer.util.DoublyConnectedEdgeList<Vertex,Edge>
- Direct Known Subclasses:
- Triangulator
public abstract class DoublyConnectedEdgeList<Vertex extends PlanarVertex,Edge extends PlanarEdge>
- extends java.lang.Object
This class represents as its name indicates a planar subdivision.
Its uses are many, but to name a few, its good for triangulation of complex polygons
(those with holes in them....).
To make a triangulation it is assumed that some subset of the edges form a closed polygon around
the rest of the triangulation. These points must be connected in counter-clockwise order,
that is the interior of the polygon they form lies to the left of every edge in it.
The internal representation of the planar subdivision does allow though to traverse the edges backwards,
since we use DCEL representation.
NOTE:
- At the moment the planar subdivision does not accept anything but 1 or two manifold vertices. If you
add more edges than that, stuff will break :-)
- Author:
- emanuel
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DoublyConnectedEdgeList
public DoublyConnectedEdgeList()
createVertex
public abstract Vertex createVertex(int index,
processing.core.PVector p)
createEdge
public abstract Edge createEdge(Vertex origin,
boolean real)
addVertex
public Vertex addVertex(processing.core.PVector p)
addEdge
public Edge addEdge(int src_i,
int dst_i)
getVertices
public java.util.ArrayList<Vertex> getVertices()