Face Class Reference

#include <face.h>

Collaboration diagram for Face:

Collaboration graph
[legend]
List of all members.

Public Member Functions

Faceoperator= (Face const &)
 Face (int const &, int const &, int const &, int const &, vec_vp &)
 Face (Face const &)
bool isMatch (int i, std::string const &name) const
void print (std::ostream &) const
void printCP (std::ostream &) const
void addEdge (Edge *)
void getBoundingBox (hxa7241_graphics::Vector3r &lower, hxa7241_graphics::Vector3r &upper) const
void getVertexCoord (vector3 const *&, vector3 const *&, vector3 const *&) const
double getAngle (Vertex const *const v) const
double getAngleProxy (Vertex const *const) const
double getAspectRatio (vector3 &, Vertex const *&) const
double getAspectRatioForceEnergy (Vertex const *const v, vector3 &force, bool compute_force) const
void updateNormal (void)
bool getFlag (void) const
void setFlag (void)
void clearFlag (void)
int getIndex (void) const
EdgegetEdge (int const &i)
VertexgetVertex (int const &i) const
vector3 const * getNormal (void) const
double computeArea (void)

Constructor & Destructor Documentation

Face::Face ( int const &  in,
int const &  v1,
int const &  v2,
int const &  v3,
vec_vp vp 
)

Creat instance of Face class.

Parameters:
[in] line Single line from input mesh file.
[in] vp Implicit mapping from vertex index to vertex pointer.

Face::Face ( Face const &   ) 


Member Function Documentation

Face & Face::operator= ( Face const &   ) 

bool Face::isMatch ( int  i,
std::string const &  name 
) const

Compare input face index and object name to this face's index and object name.

Parameters:
[in] i Input face index.
[in] name Input face parent object name.
Returns:
True if indices and names match; false otherwise.

void Face::print ( std::ostream &  target  )  const

Print identifying face information to output stream.

Parameters:
[in] target Pre-initialized output stream.

void Face::printCP ( std::ostream &  target  )  const

Print to output stream the position of each vertex of this face in DREaMM custom points format.

Parameters:
[in] target Pre-initialized output stream.

void Face::addEdge ( Edge ptr  ) 

Add input edge pointer to this face.

Parameters:
[in] ptr Edge of interest.

void Face::getBoundingBox ( hxa7241_graphics::Vector3r lower,
hxa7241_graphics::Vector3r upper 
) const

Calculate bounding box of this face.

Parameters:
[out] lower Lower corner of bounding box of this face.
[out] upper Upper corner of bounding box of this face.
Returns:
Limiting extent of face in ith direction.

void Face::getVertexCoord ( vector3 const *&  v0,
vector3 const *&  v1,
vector3 const *&  v2 
) const

Get pointers to face vertex positions.

Parameters:
[out] v0 Pointer to position of first vertex.
[out] v1 Pointer to position of second vertex.
[out] v2 Pointer to position of third vertex.

double Face::getAngle ( Vertex const *const   v  )  const

double Face::getAngleProxy ( Vertex const * const  vv  )  const

Calculate and retun a ratio of face edge lengths that behaves similarly to interior face angle.

Parameters:
[in] vv Vertex of interest.
Returns:
Ratio of length of opposite edge to sum of adjacent edges to vertex of interest.

double Face::getAspectRatio ( vector3 alt,
Vertex const *&  worst 
) const

Calculate and return aspect ratio of this face.

Returns:
Face aspect ratio as longest edge divided by perpendicular triangle height.

double Face::getAspectRatioForceEnergy ( Vertex const *const   vv,
vector3 force,
bool  compute_force 
) const

Compute and return the force vector and energy due to the aspect ratio of this face.

Parameters:
[in] v Vertex of interest.
[out] force Cumulative force.
[in] compute_force If true then compute force vector; otherwise compute energy only.

void Face::updateNormal ( void   ) 

Calculate and record face normal (not guaranteed to be unit vector).

bool Face::getFlag ( void   )  const [inline]

Get flag of this face.

Returns:
Flag value.

void Face::setFlag ( void   )  [inline]

Set flag of this face to true.

void Face::clearFlag ( void   )  [inline]

Reset flag of this face to false.

int Face::getIndex ( void   )  const [inline]

Get face index.

Returns:
The face index.

Edge* Face::getEdge ( int const &  i  )  [inline]

Get one of edges of this face.

Parameters:
[in] i Edge of interest.
Returns:
The ith edge.

Vertex* Face::getVertex ( int const &  i  )  const [inline]

Get pointer to face vertex.

Parameters:
[in] i Index (0,1,2) of face vertex of interest.
Returns:
Pointer to vertex of this face.

vector3 const* Face::getNormal ( void   )  const [inline]

Return face normal (not guaranteed to be unit vector).

Returns:
Face normal.

double Face::computeArea ( void   )  [inline]

Calculate face area.

Returns:
Face area.


The documentation for this class was generated from the following files:
Generated on Fri Feb 13 13:58:40 2009 for meshmorph by  doxygen 1.5.1