MeshNS::MeshSequence Class Reference

This class encapsulates X Polyhedron to represent a mesh sequence. More...

#include <mesh_sequence.h>

Collaboration diagram for MeshNS::MeshSequence:

Collaboration graph
[legend]

Public Member Functions

 MeshSequence ()
 MeshSequence (const std::vector< std::vector< MeshNS::SimpleVertex > > verts, const std::vector< std::vector< MeshNS::SimpleFace > > &faces, ParserNS::MeshSequenceType type)
 MeshSequence (const std::string &filename)
PolyhedronPtr operator[] (unsigned int i)
void addPolyhedron (PolyhedronPtr poly)
void push_back (PolyhedronPtr poly)
const PolyhedronPtr operator[] (unsigned int i) const
PolyhedronPtr getNext ()
const PolyhedronPtr getNext () const
std::vector< SimpleVertices > getVertices (int index=-1) const
std::vector< SimpleFaces > getFaces (int index=-1) const
size_t size ()
void invertNormal ()
ParserNS::MeshSequenceType getMSType () const
void triangulate ()

Detailed Description

This class encapsulates X Polyhedron to represent a mesh sequence.

Todo:
Template it ?
Todo:
: add support for loading progressive (should adapt the parser) mesh

Constructor & Destructor Documentation

MeshNS::MeshSequence::MeshSequence (  ) 

Default constructor.

MeshNS::MeshSequence::MeshSequence ( const std::vector< std::vector< MeshNS::SimpleVertex > >  verts,
const std::vector< std::vector< MeshNS::SimpleFace > > &  faces,
ParserNS::MeshSequenceType  type 
)

Create a mesh using already loaded vertices and faces

Parameters:
verts : the vertices of the meshes all along the sequence
faces : the faces of the meshes all along the sequence
type : the type of mesh sequence (
See also:
ParserNS::MeshSequenceType)

MeshNS::MeshSequence::MeshSequence ( const std::string &  filename  ) 

Create a mesh by loading it from filename

Parameters:
filename the file which contains the sequence (in xml.bz2)


Member Function Documentation

PolyhedronPtr MeshNS::MeshSequence::operator[] ( unsigned int  i  )  [inline]

Get the Ith Polyhedron

Parameters:
the polyhedron to get
Returns:
the Ith Polyhedron

const PolyhedronPtr MeshNS::MeshSequence::operator[] ( unsigned int  i  )  const [inline]

Get the Ith Polyhedron

Parameters:
the polyhedron to get
Returns:
the Ith Polyhedron

PolyhedronPtr MeshNS::MeshSequence::getNext (  )  [inline]

Get the next Polyhedron

Returns:
the next Polyhedron

const PolyhedronPtr MeshNS::MeshSequence::getNext (  )  const [inline]

Get the next Polyhedron

Returns:
the next Polyhedron

vector< SimpleVertices > MeshNS::MeshSequence::getVertices ( int  index = -1  )  const

Get the vertices forming the mesh all along the sequence

Returns:
the vertices forming the mesh all along the sequence

vector< SimpleFaces > MeshNS::MeshSequence::getFaces ( int  index = -1  )  const

Get the faces forming the mesh all along the sequence

Returns:
the faces forming the mesh all along the sequence

size_t MeshNS::MeshSequence::size (  )  [inline]

Number of frame of the sequence (== the number of Polyhedron stored in the MeshSequence)

Returns:
the number of frame of the sequence

void MeshNS::MeshSequence::invertNormal (  )  [inline]

Invert the normal of all the Poyhedron in the MeshSequence

ParserNS::MeshSequenceType MeshNS::MeshSequence::getMSType (  )  const [inline]

Get the type of the MeshSequence (see ParserNS::MeshSequenceType)

Returns:
the type of the MeshSequence

void MeshNS::MeshSequence::triangulate (  )  [inline]

triangulate all the Polyhedron of the sequence


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

Generated on Fri Jan 16 13:00:34 2009 by  doxygen 1.5.5