GEOS
3.8.0dev

A class that represents the edge data structure which implements the quadedge algebra. More...
#include <QuadEdge.h>
Public Member Functions  
virtual void  free () 
Free the QuadEdge quartet associated with this QuadEdge by a connect() or makeEdge() call. More...  
const QuadEdge &  getPrimary () const 
Gets the primary edge of this quadedge and its sym . More...  
virtual void  setData (void *data) 
Sets the external data value for this edge. More...  
virtual void *  getData () 
Gets the external data value for this edge. More...  
void  remove () 
Marks this quadedge as being deleted. More...  
bool  isLive () 
Tests whether this edge has been deleted. More...  
void  setNext (QuadEdge *p_next) 
Sets the connected edge. More...  
QuadEdge &  rot () const 
Gets the dual of this edge, directed from its right to its left. More...  
QuadEdge &  invRot () const 
Gets the dual of this edge, directed from its left to its right. More...  
QuadEdge &  sym () const 
Gets the edge from the destination to the origin of this edge. More...  
QuadEdge &  oNext () const 
Gets the next CCW edge around the origin of this edge. More...  
QuadEdge &  oPrev () const 
Gets the next CW edge around (from) the origin of this edge. More...  
QuadEdge &  dNext () const 
Gets the next CCW edge around (into) the destination of this edge. More...  
QuadEdge &  dPrev () const 
Gets the next CW edge around (into) the destination of this edge. More...  
QuadEdge &  lNext () const 
Gets the CCW edge around the left face following this edge. More...  
QuadEdge &  lPrev () const 
Gets the CCW edge around the left face before this edge. More...  
QuadEdge &  rNext () 
Gets the edge around the right face ccw following this edge. More...  
QuadEdge &  rPrev () 
Gets the edge around the right face ccw before this edge. More...  
void  setOrig (const Vertex &o) 
Sets the vertex for this edge's origin. More...  
void  setDest (const Vertex &d) 
Sets the vertex for this edge's destination. More...  
const Vertex &  orig () const 
Gets the vertex for the edge's origin. More...  
const Vertex &  dest () const 
Gets the vertex for the edge's destination. More...  
double  getLength () const 
Gets the length of the geometry of this quadedge. More...  
bool  equalsNonOriented (const QuadEdge &qe) const 
Tests if this quadedge and another have the same line segment geometry, regardless of orientation. More...  
bool  equalsOriented (const QuadEdge &qe) const 
Tests if this quadedge and another have the same line segment geometry with the same orientation. More...  
std::unique_ptr < geom::LineSegment >  toLineSegment () const 
Creates a geom::LineSegment representing the geometry of this edge. More...  
Static Public Member Functions  
static std::unique_ptr< QuadEdge >  makeEdge (const Vertex &o, const Vertex &d) 
Creates a new QuadEdge quartet from Vertex o to Vertex d. More...  
static std::unique_ptr< QuadEdge >  connect (QuadEdge &a, QuadEdge &b) 
Creates a new QuadEdge connecting the destination of a to the origin of b, in such a way that all three have the same left face after the connection is complete. More...  
static void  splice (QuadEdge &a, QuadEdge &b) 
Splices two edges together or apart. More...  
static void  swap (QuadEdge &e) 
Turns an edge counterclockwise inside its enclosing quadrilateral. More...  
A class that represents the edge data structure which implements the quadedge algebra.
The quadedge algebra was described in a wellknown paper by Guibas and Stolfi, "Primitives for the manipulation of general subdivisions and the computation of Voronoi diagrams", ACM Transactions on Graphics, 4(2), 1985, 75123.
Each edge object is part of a quartet of 4 edges, linked via their _rot
references. Any edge in the group may be accessed using a series of rot() operations. Quadedges in a subdivision are linked together via their next
references. The linkage between the quadedge quartets determines the topology of the subdivision.
The edge class does not contain separate information for vertice or faces; a vertex is implicitly defined as a ring of edges (created using the next
field).

static 
Creates a new QuadEdge connecting the destination of a to the origin of b, in such a way that all three have the same left face after the connection is complete.
Additionally, the data pointers of the new edge are set.

inline 
Gets the vertex for the edge's destination.

inline 

inline 
bool geos::triangulate::quadedge::QuadEdge::equalsNonOriented  (  const QuadEdge &  qe  )  const 
Tests if this quadedge and another have the same line segment geometry, regardless of orientation.
qe  a quadege 
true
if the quadedges are based on the same line segment regardless of orientation bool geos::triangulate::quadedge::QuadEdge::equalsOriented  (  const QuadEdge &  qe  )  const 
Tests if this quadedge and another have the same line segment geometry with the same orientation.
qe  a quadege 
true
if the quadedges are based on the same line segment

virtual 
Free the QuadEdge quartet associated with this QuadEdge by a connect() or makeEdge() call.

virtual 
Gets the external data value for this edge.

inline 
Gets the length of the geometry of this quadedge.
const QuadEdge& geos::triangulate::quadedge::QuadEdge::getPrimary  (  )  const 
Gets the primary edge of this quadedge and its sym
.
The primary edge is the one for which the origin and destination coordinates are ordered according to the standard geom::Coordinate ordering

inline 

inline 
Tests whether this edge has been deleted.
true
if this edge has not been deleted.

inline 

inline 
Gets the CCW edge around the left face before this edge.
References sym().

inline 

inline 

inline 
Gets the vertex for the edge's origin.
void geos::triangulate::quadedge::QuadEdge::remove  (  ) 
Marks this quadedge as being deleted.
This does not free the memory used by this quadedge quartet, but indicates that this quadedge quartet no longer participates in a subdivision.

inline 

inline 

inline 
Gets the edge around the right face ccw before this edge.
References oNext().

virtual 
Sets the external data value for this edge.
data  an object containing external data 

inline 
Sets the vertex for this edge's destination.
d  the destination vertex 

inline 
Sets the connected edge.
p_next  edge 

inline 
Sets the vertex for this edge's origin.
o  the origin vertex 
Splices two edges together or apart.
Splice affects the two edge rings around the origins of a and b, and, independently, the two edge rings around the left faces of a
and b
. In each case, (i) if the two rings are distinct, Splice will combine them into one, or (ii) if the two are the same ring, Splice will break it into two separate pieces. Thus, Splice can be used both to attach the two edges together, and to break them apart.
a  an edge to splice 
b  an edge to splice 

static 
Turns an edge counterclockwise inside its enclosing quadrilateral.
e  the quadedge to turn 

inline 
std::unique_ptr<geom::LineSegment> geos::triangulate::quadedge::QuadEdge::toLineSegment  (  )  const 
Creates a geom::LineSegment representing the geometry of this edge.