Delaunator
2D Delaunay Triangulation in C++ with Python wrapper.
 All Classes Namespaces Functions
Public Member Functions | List of all members
VertexGroup Class Reference

#include <vertexGroup.h>

Inheritance diagram for VertexGroup:
Vertex Coordinates

Public Member Functions

 VertexGroup ()
 ~VertexGroup ()
unsigned int neighbourCount () const
void take (VirtualVertex *, Vertex *=NULL)
void giveVirtualVerticesTo (Vertex *)
void forget (VirtualVertex *)
unsigned int getObjectCount () const
unsigned int getVertexCount () const
std::list< VirtualVertex * > getObjects (unsigned int=0) const
VirtualVertexgetFirstObject () const
bool isNeighbourOf (Vertex *) const
bool isACorner () const
bool have (VirtualVertex *) const
- Public Member Functions inherited from Vertex
 Vertex (const float=0., const float=0., Edge *=NULL)
 Vertex (const Coordinates c, Edge *=NULL)
 ~Vertex ()
unsigned int getID () const
EdgegetEdge () const
void setEdge (Edge *e)
- Public Member Functions inherited from Coordinates
 Coordinates (const float x=0., const float y=0.)
float squareDistanceTo (const Coordinates &othr) const
float distanceTo (const Coordinates &othr) const
float x () const
float y () const
void setX (float x)
void setY (float y)
void setCoord (float x, float y)
bool operator== (const Coordinates &othr)
bool operator!= (const Coordinates &othr)
Coordinates operator+ (const Coordinates &c)
Coordinates operator- (const Coordinates &c)
Coordinates operator/ (const float value)
Coordinates operator+= (const Coordinates &c)

Detailed Description

VertexGroup are Vertex, according to Composite pattern. Vertices of a VertexGroup moves together. IMPLEMENTATION INCOMPLETE

Constructor & Destructor Documentation

VertexGroup::VertexGroup ( )

Creat a new VertexGroup.

Returns
a new and well initialized VertexGroup
VertexGroup::~VertexGroup ( )

Destructor Forget all VirtualVertex

Member Function Documentation

void VertexGroup::forget ( VirtualVertex trob)
Parameters
troba VirtualVertex that will be forgeted by this
Note
if this have not trob in memory, nothing is done by that function.
trob is not modified

Reimplemented from Vertex.

VirtualVertex * VertexGroup::getFirstObject ( ) const

Access to one VirtualVertex of this instance.

Returns
a VirtualVertex pointer, or NULL if no Object referenced

Reimplemented from Vertex.

std::list< VirtualVertex * > VertexGroup::getObjects ( unsigned int  nb = 0) const

Access to all VirtualVertexG of this instance.

Parameters
nbnumber of objects returned. If 0, default or greater than object count, all are returned.
Returns
a std::list of VirtualVertex pointers

Reimplemented from Vertex.

void VertexGroup::giveVirtualVerticesTo ( Vertex v)
Parameters
va VertexGroup that will receive all VirtualVertex of this

Reimplemented from Vertex.

bool VertexGroup::have ( VirtualVertex vv) const
Parameters
vva VirtualVertex address
Returns
true iff this have vv in objects list

Reimplemented from Vertex.

bool VertexGroup::isACorner ( ) const
Returns
true iff this is referenced by triangulation and is one of the four corner vertice

Reimplemented from Vertex.

bool VertexGroup::isNeighbourOf ( Vertex v) const
Parameters
va VertexGroup return true iff an edge have for origin this and for destination v

Reimplemented from Vertex.

void VertexGroup::take ( VirtualVertex trob,
Vertex ancient = NULL 
)
Parameters
troba VirtualVertex that will be added in list of this
ancientthe Vertex that have trob, and that will forget it, or NULL (default value)
Note
trob is modified by a call to setVertexGroup(this)

Reimplemented from Vertex.


The documentation for this class was generated from the following files: