Navigation: Up, Table of Contents, Bibliography, Index, Title Page

The vertex stores a point and a pointer to an incident face.

Inherits From

Tds::Vertex_base

Types

The class Tds::Vertex defines the same types as the triangulation data structure class Tds except the iterators.
begin of advanced section

Creation

Tds::Vertex v;
introduces a vertex v. The geometric information is initialized by the default constructor of class Point. The pointer to the incident face is initialized with NULL.


Tds::Vertex v ( Point p);
introduces a vertex v, and initializes the geometric information. The pointer to the incident face is initialized with NULL.


Tds::Vertex v ( Point p, Face* f);
introduces a vertex v, and initializes the geometric information and the pointer to the incident face.

Setting

void v.set_point ( Point p)
sets the geometric information to p.
void v.set_face ( Face* f)
sets the incident face to f.


end of advanced section

Access Functions

Point v.point () returns the geometric information of v.
Face* v.face () returns a face of the triangulation having v as vertex.

Traversal of the Adjacent Vertices, Incident Edges and Faces.

Three circulator classes allow to traverse the edges, and faces incident to a given vertex and the adjacent vertices. Note that infinite as well as finite incident edges and faces are visited. These circulators are bidirectional and their value types are respectively Vertex, Edge and Face. The operator++ moves the circulator counterclockwise around the vertex and the operator-- moves the circulator clockwise.

A face circulator is invalidated by any modification of the face it points to. An edge circulator is invalidated by any modification of anyone of the two faces incident to the edge pointed to. A vertex circulator that turns around vertex v and that has as value a pointer to vertex w, is invalidated by any modification of anyone of the two faces incident to v and w.

Vertex_circulator v.incident_vertices ( Face* f=NULL)
Edge_circulator v.incident_edges ( Face* f=NULL)
Face_circulator v.incident_faces ( Face* f=NULL)

Miscellaneous

int v.ccw ( int i) Returns i+1 modulo 3.
Precondition: 0 i 2.
int v.cw ( int i) Returns i+2 modulo 3.
Precondition: 0 i 2.
int v.degree () Returns the degree of v in the triangulation.


Next: Class declaration of Tds::Face
Navigation: Up, Table of Contents, Bibliography, Index, Title Page
The GALIA project. Jan 18, 2000.