Main Page | Modules | Namespace List | Class Hierarchy | Class List | Namespace Members | Class Members

TriangulatedSurface Class Reference
[Molecular Surface Computation]

Generic TriangulatedSurface Class. More...

#include <triangulatedSurface.h>

Inheritance diagram for TriangulatedSurface:

TriangulatedSAS TriangulatedSES TriangulatedSphere List of all members.

Public Types

Type definitions
typedef std::list< TrianglePoint
* >::iterator 
PointIterator
typedef std::list< TrianglePoint
* >::const_iterator 
ConstPointIterator
typedef std::list< TriangleEdge
* >::iterator 
EdgeIterator
typedef std::list< TriangleEdge
* >::const_iterator 
ConstEdgeIterator
typedef std::list< Triangle
* >::iterator 
TriangleIterator
typedef std::list< Triangle
* >::const_iterator 
ConstTriangleIterator

Public Member Functions

Constructors and Destructors
 TriangulatedSurface () throw ()
 Default constructor.
 TriangulatedSurface (const TriangulatedSurface &surface, bool=true) throw ()
 Copy constructor.
virtual ~TriangulatedSurface () throw ()
 Destructor.
Assignment
void clear () throw ()
 Delete all points, edges and triangles.
void set (const TriangulatedSurface &surface, bool=true) throw ()
 Assign from another TriangulatedSurface.
TriangulatedSurfaceoperator= (const TriangulatedSurface &surface) throw ()
 Assign from another TriangulatedSurface.
Accessors
void insert (TrianglePoint *point) throw ()
 Insert a new point to the TriangulatedSurface.
void insert (TriangleEdge *edge) throw ()
 Insert a new edge to the TriangulatedSurface.
void insert (Triangle *triangle) throw ()
 Insert a new triangle to the TriangulatedSurface.
Size numberOfPoints () const throw ()
 Get the number of points of the TriangulatedSurface.
Size numberOfEdges () const throw ()
 Get the number of edges of the TriangulatedSurface.
Size numberOfTriangles () const throw ()
 Get the number of triangles of the TriangulatedSurface.
void remove (TrianglePoint *point, bool deep=true) throw ()
 Remove a point from the TriangulatedSurface.
void remove (PointIterator p, bool deep=true) throw ()
 Remove a point from the TriangulatedSurface.
void remove (TriangleEdge *edge, bool deep=true) throw ()
 Remove an edge from the TriangulatedSurface.
void remove (EdgeIterator e, bool deep=true) throw ()
 Remove an edge from the TriangulatedSurface.
void remove (Triangle *triangle, bool deep=true) throw ()
 Remove a triangle from the TriangulatedSurface.
void remove (TriangleIterator t, bool deep=true) throw ()
 Remove a triangle from the TriangulatedSurface.
void exportSurface (Surface &surface) throw ()
 Create a Surface object from the TriangulatedeSurface.
TriangulatedSurfaceoperator+= (const TriangulatedSurface &surface) throw ()
 Add a TriangulatedSurface object.
void join (TriangulatedSurface &source) throw ()
 Add a TriangulatedSurface object.
void shift (const TVector3< double > &c)
 Shift the TriangulatedSurface.
void blowUp (const double &r)
 Blow up th TriangulatedSurface.
void setIndices ()
 Set the indices of al points, edges and triangles.
void cut (const TPlane3< double > &plane, const double &fuzzy=0)
 Cut the TriangulatedSurface on a plane.
void shrink ()
 Delete all triangles on the border of the TriangulatedSurface.
void deleteIsolatedEdges () throw ()
 Delete all isolated edges of the TriangulatedSurface.
void deleteIsolatedPoints () throw ()
 Delete all isolated points of the TriangulatedSurface.
void getBorder (std::list< TriangleEdge * > &border)
 Get the border edges of the TriangulatedSurface.
External Iterators
PointIterator beginPoint () throw ()
ConstPointIterator beginPoint () const throw ()
PointIterator endPoint () throw ()
ConstPointIterator endPoint () const throw ()
EdgeIterator beginEdge () throw ()
ConstEdgeIterator beginEdge () const throw ()
EdgeIterator endEdge () throw ()
ConstEdgeIterator endEdge () const throw ()
TriangleIterator beginTriangle () throw ()
ConstTriangleIterator beginTriangle () const throw ()
TriangleIterator endTriangle () throw ()
ConstTriangleIterator endTriangle () const throw ()

Protected Member Functions

bool canBeCopied () const throw ()
void copy (const TriangulatedSurface &surface) throw ()

Protected Attributes

Size number_of_points_
std::list< TrianglePoint * > points_
Size number_of_edges_
std::list< TriangleEdge * > edges_
Size number_of_triangles_
std::list< Triangle * > triangles_

Detailed Description

Generic TriangulatedSurface Class.


Constructor & Destructor Documentation

TriangulatedSurface::TriangulatedSurface  )  throw ()
 

Default constructor.

This method creates a new TriangulatedSurface object.

TriangulatedSurface::TriangulatedSurface const TriangulatedSurface surface,
bool  = true
throw ()
 

Copy constructor.

Create a new TriangulatedSurface object from another.

Parameters:
surface the TriangulatedSurface object to be copied
bool ignored - just for interface consistency

virtual TriangulatedSurface::~TriangulatedSurface  )  throw () [virtual]
 

Destructor.

Destructs the TriangulatedSurface object.


Member Function Documentation

void TriangulatedSurface::blowUp const double &  r  ) 
 

Blow up th TriangulatedSurface.

All points are multiplied by a scalar r.

Parameters:
r the blow up factor

void TriangulatedSurface::clear  )  throw ()
 

Delete all points, edges and triangles.

void TriangulatedSurface::cut const TPlane3< double > &  plane,
const double &  fuzzy = 0
 

Cut the TriangulatedSurface on a plane.

Parameters:
plane the plane to cut on
fuzzy 

void TriangulatedSurface::exportSurface Surface surface  )  throw ()
 

Create a Surface object from the TriangulatedeSurface.

Parameters:
surface the created Surface object

void TriangulatedSurface::getBorder std::list< TriangleEdge * > &  border  ) 
 

Get the border edges of the TriangulatedSurface.

Border edges are the edges with only one triangle.

Parameters:
border a list of the border edges

void TriangulatedSurface::insert Triangle triangle  )  throw ()
 

Insert a new triangle to the TriangulatedSurface.

Parameters:
triangle a pointer to the new triangle

void TriangulatedSurface::insert TriangleEdge edge  )  throw ()
 

Insert a new edge to the TriangulatedSurface.

Parameters:
edge a pointer to the new edge

void TriangulatedSurface::insert TrianglePoint point  )  throw ()
 

Insert a new point to the TriangulatedSurface.

Parameters:
point a pointer to the new point

void TriangulatedSurface::join TriangulatedSurface source  )  throw ()
 

Add a TriangulatedSurface object.

The lists of points, edges and triangles of the given TriangulatedSurface objact are appended. After this operation, the given TriangulatedSurface objact will be empty!

Parameters:
source the TriangulatedSurface object to add

Size TriangulatedSurface::numberOfEdges  )  const throw ()
 

Get the number of edges of the TriangulatedSurface.

Size TriangulatedSurface::numberOfPoints  )  const throw ()
 

Get the number of points of the TriangulatedSurface.

Size TriangulatedSurface::numberOfTriangles  )  const throw ()
 

Get the number of triangles of the TriangulatedSurface.

TriangulatedSurface& TriangulatedSurface::operator+= const TriangulatedSurface surface  )  throw ()
 

Add a TriangulatedSurface object.

The lists of points, edges and triangles of the given TriangulatedSurface objact are appended. The given TriangulatedSurface objact will be unchanged.

Parameters:
surface the TriangulatedSurface object to add

TriangulatedSurface& TriangulatedSurface::operator= const TriangulatedSurface surface  )  throw ()
 

Assign from another TriangulatedSurface.

Parameters:
surface the TriangulatedSurface object to assign from

void TriangulatedSurface::remove TriangleIterator  t,
bool  deep = true
throw ()
 

Remove a triangle from the TriangulatedSurface.

If deep is true (not default) the incidence-structure will be updated.

Parameters:
t an iterator into the list of triangles of the TriangulatedSurface which indicates the triangle to delete
deep look above

void TriangulatedSurface::remove Triangle triangle,
bool  deep = true
throw ()
 

Remove a triangle from the TriangulatedSurface.

If deep is true (not default) the incidence-structure will be updated.

Parameters:
triangle a pointer to the triangle to delete
deep look above

void TriangulatedSurface::remove EdgeIterator  e,
bool  deep = true
throw ()
 

Remove an edge from the TriangulatedSurface.

If deep is true (not default) the incidence-structure will be updated.

Parameters:
e an iterator into the list of edges of the TriangulatedSurface which indicates the edge to delete
deep look above

void TriangulatedSurface::remove TriangleEdge edge,
bool  deep = true
throw ()
 

Remove an edge from the TriangulatedSurface.

If deep is true (not default) the incidence-structure will be updated.

Parameters:
edge a pointer to the edge to delete
deep look above

void TriangulatedSurface::remove PointIterator  p,
bool  deep = true
throw ()
 

Remove a point from the TriangulatedSurface.

If deep is true (default) the incidence-structure will be updated.

Parameters:
p an iterator into the list of points of the TriangulatedSurface which indicates the point to delete
deep look above

void TriangulatedSurface::remove TrianglePoint point,
bool  deep = true
throw ()
 

Remove a point from the TriangulatedSurface.

If deep is true (default) the incidence-structure will be updated.

Parameters:
point a pointer to the point to delete
deep look above

void TriangulatedSurface::set const TriangulatedSurface surface,
bool  = true
throw ()
 

Assign from another TriangulatedSurface.

Parameters:
surface the TriangulatedSurface object to assign from
bool ignored - just for interface consistency

void TriangulatedSurface::setIndices  ) 
 

Set the indices of al points, edges and triangles.

void TriangulatedSurface::shift const TVector3< double > &  c  ) 
 

Shift the TriangulatedSurface.

All points are shifted by a vector c.

Parameters:
c the shift vector