The Parametric Pseudo-Manifold (PPS) Library 1.0
dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib > Class Template Reference

This class represents a face (i.e., a triangle) from a surface mesh represented by the DCEL data structure. More...

#include <face.h>

Collaboration diagram for dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >:

List of all members.

Public Types

typedef dcel::Halfedge
< VAttrib, FAttrib, EAttrib,
HAttrib > 
Halfedge
 Defines Halfedge as an alias for dcel::Halfedge< VAttrib, FAttrib , EAttrib , HAttrib >.

Public Member Functions

 Face (Halfedge *h)
 Creates an instance of this class.
 ~Face ()
 Destroys an instance of this class.
Halfedgeget_halfedge () const
 Returns a pointer to the first half-edge of this face.
void set_halfedge (Halfedge *h)
 Assigns an address to the pointer to the first half-edge of this face.
FAttrib & get_attributes ()
 Returns the set of attributes associated with this face.

Private Attributes

Halfedge_halfedge
 Pointer to the first half-edge of the half-edge cycle of this face.
FAttrib _attributes
 Set of attributes associated with this face.

Detailed Description

template<typename VAttrib, typename FAttrib, typename EAttrib, typename HAttrib>
class dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >

This class represents a face (i.e., a triangle) from a surface mesh represented by the DCEL data structure.

Definition at line 61 of file face.h.


Constructor & Destructor Documentation

template<typename VAttrib , typename FAttrib , typename EAttrib , typename HAttrib >
dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >::Face ( Halfedge h) [inline]

Creates an instance of this class.

Parameters:
hA pointer to the first halfedge of this face.

Definition at line 92 of file face.h.

                        : _halfedge( h )
    {}

Member Function Documentation

template<typename VAttrib , typename FAttrib , typename EAttrib , typename HAttrib >
FAttrib & dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >::get_attributes ( ) [inline]

Returns the set of attributes associated with this face.

Returns:
A reference to the set of attributes associated with this face.

Definition at line 142 of file face.h.

References dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >::_attributes.

    {
      return _attributes ; 
    }
template<typename VAttrib , typename FAttrib , typename EAttrib , typename HAttrib >
Halfedge * dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >::get_halfedge ( ) const [inline]

Returns a pointer to the first half-edge of this face.

Returns:
A pointer to the first half-edge of this face.

Definition at line 114 of file face.h.

References dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >::_halfedge.

    {
      return _halfedge ; 
    }
template<typename VAttrib , typename FAttrib , typename EAttrib , typename HAttrib >
void dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >::set_halfedge ( Halfedge h) [inline]

Assigns an address to the pointer to the first half-edge of this face.

Parameters:
hThe address of the first half-edge of this face.

Definition at line 128 of file face.h.

References dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >::_halfedge.

Referenced by dcel::Surface< VAttrib, FAttrib, EAttrib, HAttrib >::create_faces(), and dcel::Face< VAttrib, FAttrib, EAttrib, HAttrib >::~Face().

    {
      _halfedge = h ; 
    }

The documentation for this class was generated from the following file: