Main Page | Modules | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

Arak::Coloring::Vertex Class Reference

#include <coloring.hpp>

Collaboration diagram for Arak::Coloring::Vertex:

Collaboration graph
[legend]
List of all members.

Detailed Description

A vertex joins interior and/or boundary edges.

Definition at line 338 of file coloring.hpp.

Public Types

enum  Type { INTERIOR, BOUNDARY, CORNER, INVALID }
 The type of the vertex (INTERIOR, BOUNDARY, or CORNER). More...


Public Member Functions

 Vertex ()
 Default constructor.

Type type () const
 Returns the type of this vertex.

const Geometry::Pointpoint () const
 Returns a point representation of the vertex.

bool hasPrevIntEdge () const
 Returns true if this vertex has a previous interior edge.

IntEdgeHandle getPrevIntEdge ()
 Returns a reference to the previous edge incident to this vertex (for some ordering of the path's vertices).

const IntEdgeHandle getPrevIntEdge () const
bool hasNextIntEdge () const
 Returns true if this vertex has a next interior edge.

IntEdgeHandle getNextIntEdge ()
 Returns a reference to the next interior edge incident to this vertex (for some ordering of the path's vertices).

const IntEdgeHandle getNextIntEdge () const
BdEdgeHandle getPrevBdEdge ()
 Returns a reference to the previous boundary edge incident to this vertex (for some ordering of the boundary vertices).

const BdEdgeHandle getPrevBdEdge () const
BdEdgeHandle getNextBdEdge ()
 Returns a reference to the next boundary edge incident to this vertex (for some ordering of the boundary vertices).

const BdEdgeHandle getNextBdEdge () const
VertexHandle getPrevVertex ()
 Returns a reference to the vertex before this vertex in the ordering of the polygon's vertices.

const VertexHandle getPrevVertex () const
VertexHandle getNextVertex ()
 Returns a reference to the vertex after this vertex in the ordering of the polygon's vertices.

const VertexHandle getNextVertex () const
VertexHandle getPrevCornerVertex ()
 Returns a reference to the previous corner vertex preceding this boundary vertex.

const VertexHandle getPrevCornerVertex () const
VertexHandle getNextCornerVertex ()
 Returns a reference to the next corner vertex following this boundary vertex.

const VertexHandle getNextCornerVertex () const
double logSine ()
 If this vertex is an interior vertex, this computes the log of the sine of the smaller angle between the two incident edges; if this vertex is a boundary vertex, this computes the log of the sine of the smaller angle between the true incident edge and the boundary tangent.


Protected Attributes

Type t
 The type of this vertex.

IntEdgeHandle prevIntEdge
 A handle on the previous interior edge incident to this vertex (for some ordering of the path's vertices).

IntEdgeHandle nextIntEdge
 A pointer to the next interior edge incident to this vertex (for some ordering of the path's vertices).

BdEdgeHandle prevBdEdge
 If this vertex is of type BOUNDARY, then this points to the previous boundary edge incident to this vertex (for some ordering of the boundary edges).

BdEdgeHandle nextBdEdge
 If this vertex is of type BOUNDARY, then this points to the next boundary edge incident to this vertex (for some ordering of the boundary edges).

int index
 The index of this vertex in the random access vectors.


Friends

class InteriorEdge
class BoundaryEdge
class Coloring


Member Enumeration Documentation

enum Arak::Coloring::Vertex::Type
 

The type of the vertex (INTERIOR, BOUNDARY, or CORNER).

Enumeration values:
INTERIOR  A polygon vertex that is inside the colored region.
BOUNDARY  A polygon vertex on the boundary of the colored region.
CORNER  A vertex of the boundary of the colored region.
INVALID  A vertex that is not currently * in use.

Definition at line 349 of file coloring.hpp.

Referenced by type().


Constructor & Destructor Documentation

Arak::Coloring::Vertex::Vertex  )  [inline]
 

Default constructor.

Definition at line 418 of file coloring.hpp.

References index, INVALID, and t.


Member Function Documentation

const BdEdgeHandle Arak::Coloring::Vertex::getNextBdEdge  )  const [inline]
 

Definition at line 508 of file coloring.hpp.

References Arak::Coloring::BdEdgeHandle, BOUNDARY, CORNER, nextBdEdge, and type().

BdEdgeHandle Arak::Coloring::Vertex::getNextBdEdge  )  [inline]
 

Returns a reference to the next boundary edge incident to this vertex (for some ordering of the boundary vertices).

This vertex must be of type BOUNDARY or CORNER.

Definition at line 504 of file coloring.hpp.

References Arak::Coloring::BdEdgeHandle, BOUNDARY, CORNER, nextBdEdge, and type().

Referenced by getNextCornerVertex(), and logSine().

const VertexHandle Arak::Coloring::Vertex::getNextCornerVertex  )  const [inline]
 

Definition at line 555 of file coloring.hpp.

References getNextBdEdge(), and Arak::Coloring::VertexHandle.

VertexHandle Arak::Coloring::Vertex::getNextCornerVertex  )  [inline]
 

Returns a reference to the next corner vertex following this boundary vertex.

This method signals an error if this vertex is not a boundary vertex.

Definition at line 552 of file coloring.hpp.

References getNextBdEdge(), and Arak::Coloring::VertexHandle.

const IntEdgeHandle Arak::Coloring::Vertex::getNextIntEdge  )  const [inline]
 

Definition at line 480 of file coloring.hpp.

References CORNER, Arak::Coloring::IntEdgeHandle, nextIntEdge, and type().

IntEdgeHandle Arak::Coloring::Vertex::getNextIntEdge  )  [inline]
 

Returns a reference to the next interior edge incident to this vertex (for some ordering of the path's vertices).

This vertex must not be of type CORNER, and it must have a next interior edge.

Definition at line 476 of file coloring.hpp.

References CORNER, Arak::Coloring::IntEdgeHandle, nextIntEdge, and type().

Referenced by getNextVertex().

const VertexHandle Arak::Coloring::Vertex::getNextVertex  )  const [inline]
 

Definition at line 531 of file coloring.hpp.

References getNextIntEdge(), and Arak::Coloring::VertexHandle.

VertexHandle Arak::Coloring::Vertex::getNextVertex  )  [inline]
 

Returns a reference to the vertex after this vertex in the ordering of the polygon's vertices.

Definition at line 528 of file coloring.hpp.

References getNextIntEdge(), and Arak::Coloring::VertexHandle.

Referenced by logSine().

const BdEdgeHandle Arak::Coloring::Vertex::getPrevBdEdge  )  const [inline]
 

Definition at line 494 of file coloring.hpp.

References Arak::Coloring::BdEdgeHandle, BOUNDARY, CORNER, prevBdEdge, and type().

BdEdgeHandle Arak::Coloring::Vertex::getPrevBdEdge  )  [inline]
 

Returns a reference to the previous boundary edge incident to this vertex (for some ordering of the boundary vertices).

This vertex must be of type BOUNDARY or CORNER.

Definition at line 490 of file coloring.hpp.

References Arak::Coloring::BdEdgeHandle, BOUNDARY, CORNER, prevBdEdge, and type().

Referenced by getPrevCornerVertex(), and logSine().

const VertexHandle Arak::Coloring::Vertex::getPrevCornerVertex  )  const [inline]
 

Definition at line 543 of file coloring.hpp.

References getPrevBdEdge(), and Arak::Coloring::VertexHandle.

VertexHandle Arak::Coloring::Vertex::getPrevCornerVertex  )  [inline]
 

Returns a reference to the previous corner vertex preceding this boundary vertex.

This method signals an error if this vertex is not a boundary vertex.

Definition at line 540 of file coloring.hpp.

References getPrevBdEdge(), and Arak::Coloring::VertexHandle.

const IntEdgeHandle Arak::Coloring::Vertex::getPrevIntEdge  )  const [inline]
 

Definition at line 455 of file coloring.hpp.

References CORNER, Arak::Coloring::IntEdgeHandle, prevIntEdge, and type().

IntEdgeHandle Arak::Coloring::Vertex::getPrevIntEdge  )  [inline]
 

Returns a reference to the previous edge incident to this vertex (for some ordering of the path's vertices).

This vertex must not be of type CORNER, and it must have a previous interior edge.

Definition at line 451 of file coloring.hpp.

References CORNER, Arak::Coloring::IntEdgeHandle, prevIntEdge, and type().

Referenced by getPrevVertex().

const VertexHandle Arak::Coloring::Vertex::getPrevVertex  )  const [inline]
 

Definition at line 520 of file coloring.hpp.

References getPrevIntEdge(), and Arak::Coloring::VertexHandle.

VertexHandle Arak::Coloring::Vertex::getPrevVertex  )  [inline]
 

Returns a reference to the vertex before this vertex in the ordering of the polygon's vertices.

Definition at line 517 of file coloring.hpp.

References getPrevIntEdge(), and Arak::Coloring::VertexHandle.

Referenced by logSine().

bool Arak::Coloring::Vertex::hasNextIntEdge  )  const [inline]
 

Returns true if this vertex has a next interior edge.

If it does not, then it is a boundary vertex at the end of a path and calling getNextIntEdge() will yield an error.

Definition at line 465 of file coloring.hpp.

References CORNER, nextIntEdge, type(), and PointerHandle< T >::valid().

bool Arak::Coloring::Vertex::hasPrevIntEdge  )  const [inline]
 

Returns true if this vertex has a previous interior edge.

If it does not, then it is a boundary vertex at the start of a path and calling getPrevIntEdge() will yield an error.

Definition at line 440 of file coloring.hpp.

References CORNER, prevIntEdge, type(), and PointerHandle< T >::valid().

Referenced by logSine().

double Coloring::Vertex::logSine  ) 
 

If this vertex is an interior vertex, this computes the log of the sine of the smaller angle between the two incident edges; if this vertex is a boundary vertex, this computes the log of the sine of the smaller angle between the true incident edge and the boundary tangent.

It is an error to invoke this method on a vertex that is not of type BOUNDARY or INTERIOR.

Returns:
the log of the sine of the angle associated with the vertex

Definition at line 26 of file coloring.cpp.

References BOUNDARY, getNextBdEdge(), getNextVertex(), getPrevBdEdge(), getPrevVertex(), hasPrevIntEdge(), INTERIOR, Arak::Geometry::logSineB(), point(), Arak::Geometry::Point, and type().

const Geometry::Point& Arak::Coloring::Vertex::point  )  const [inline]
 

Returns a point representation of the vertex.

Definition at line 433 of file coloring.hpp.

References Arak::Geometry::Point.

Referenced by logSine().

Type Arak::Coloring::Vertex::type  )  const [inline]
 

Returns the type of this vertex.

Returns:
the type of this vertex

Definition at line 428 of file coloring.hpp.

References t, and Type.

Referenced by getNextBdEdge(), getNextIntEdge(), getPrevBdEdge(), getPrevIntEdge(), hasNextIntEdge(), hasPrevIntEdge(), and logSine().


Friends And Related Function Documentation

friend class BoundaryEdge [friend]
 

Definition at line 341 of file coloring.hpp.

friend class Coloring [friend]
 

Definition at line 342 of file coloring.hpp.

friend class InteriorEdge [friend]
 

Definition at line 340 of file coloring.hpp.


Member Data Documentation

int Arak::Coloring::Vertex::index [protected]
 

The index of this vertex in the random access vectors.

If this vertex is of type INTERIOR, then this its index in interiorVertices; if this vertex is of type BOUNDARY, then this is its index in boundaryVertices; and if this vertex is of type CORNER, then this is its index in cornerVertices. If this vertex is unused (of type INVALID), then this is -1.

Definition at line 411 of file coloring.hpp.

Referenced by Vertex().

BdEdgeHandle Arak::Coloring::Vertex::nextBdEdge [protected]
 

If this vertex is of type BOUNDARY, then this points to the next boundary edge incident to this vertex (for some ordering of the boundary edges).

Otherwise, this is NULL.

Definition at line 401 of file coloring.hpp.

Referenced by getNextBdEdge().

IntEdgeHandle Arak::Coloring::Vertex::nextIntEdge [protected]
 

A pointer to the next interior edge incident to this vertex (for some ordering of the path's vertices).

If this is a CORNER vertex, then this pointer is NULL.

Definition at line 387 of file coloring.hpp.

Referenced by getNextIntEdge(), and hasNextIntEdge().

BdEdgeHandle Arak::Coloring::Vertex::prevBdEdge [protected]
 

If this vertex is of type BOUNDARY, then this points to the previous boundary edge incident to this vertex (for some ordering of the boundary edges).

Otherwise, this is NULL.

Definition at line 394 of file coloring.hpp.

Referenced by getPrevBdEdge().

IntEdgeHandle Arak::Coloring::Vertex::prevIntEdge [protected]
 

A handle on the previous interior edge incident to this vertex (for some ordering of the path's vertices).

If this is a CORNER vertex, then this pointer is NULL.

Definition at line 380 of file coloring.hpp.

Referenced by getPrevIntEdge(), and hasPrevIntEdge().

Type Arak::Coloring::Vertex::t [protected]
 

The type of this vertex.

Note that a vertex of type Coloring::Vertex::CORNER is not a true vertex of the coloring.

Definition at line 373 of file coloring.hpp.

Referenced by type(), and Vertex().


The documentation for this class was generated from the following files:
Generated on Wed May 25 14:41:00 2005 for Arak by doxygen 1.3.6