Main Page   Namespace List   Compound List   File List   Compound Members   File Members  

PointAverage Struct Reference

convenience function class for accumulating the average point. More...

#include <PointAverage.h>

List of all members.

Public Methods

 PointAverage ()
 initializer. More...

void operator() (Coordinate &p)
 accumulator for use in stl loops. More...

Coordinate result ()
 return the average as a Coordinate. More...


Private Attributes

GLdouble xSum
GLdouble ySum
 the sum of x coordinates. More...

GLdouble zSum
 the sum of y coordinates. More...

size_t numPoints
 the sum of z coordinates. More...


Detailed Description

convenience function class for accumulating the average point.

Definition at line 24 of file PointAverage.h.


Constructor & Destructor Documentation

PointAverage::PointAverage   [inline]
 

initializer.

Definition at line 28 of file PointAverage.h.

References numPoints, xSum, ySum, and zSum.


Member Function Documentation

void PointAverage::operator() Coordinate   p [inline]
 

accumulator for use in stl loops.

Definition at line 33 of file PointAverage.h.

References Coordinate::get_x, Coordinate::get_y, Coordinate::get_z, numPoints, xSum, ySum, and zSum.

Coordinate PointAverage::result   [inline]
 

return the average as a Coordinate.

Definition at line 42 of file PointAverage.h.

References numPoints, xSum, ySum, and zSum.


Member Data Documentation

size_t PointAverage::numPoints [private]
 

the sum of z coordinates.

Definition at line 51 of file PointAverage.h.

Referenced by operator(), PointAverage, and result.

GLdouble PointAverage::xSum [private]
 

Definition at line 48 of file PointAverage.h.

Referenced by operator(), PointAverage, and result.

GLdouble PointAverage::ySum [private]
 

the sum of x coordinates.

Definition at line 49 of file PointAverage.h.

Referenced by operator(), PointAverage, and result.

GLdouble PointAverage::zSum [private]
 

the sum of y coordinates.

Definition at line 50 of file PointAverage.h.

Referenced by operator(), PointAverage, and result.


The documentation for this struct was generated from the following file:
Generated on Wed Oct 29 10:01:53 2003 for Tetraviewer by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002