- Cal3D 0.9 API Reference -

Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   Related Pages  

CalMesh Class Reference

The mesh class. More...

#include <mesh.h>

List of all members.

Public Methods

 CalMesh ()
 Constructs the mesh instance. More...

virtual ~CalMesh ()
 Destructs the mesh instance. More...

bool create (CalCoreMesh *pCoreMesh)
 Creates the mesh instance. More...

void destroy ()
 Destroys the mesh instance. More...

CalCoreMeshgetCoreMesh ()
 Provides access to the core mesh. More...

CalSubmeshgetSubmesh (int id)
 Provides access to a submesh. More...

int getSubmeshCount ()
 Returns the number of submeshes. More...

std::vector< CalSubmesh * > & getVectorSubmesh ()
 Returns the submesh vector. More...

void setLodLevel (float lodLevel)
 Sets the LOD level. More...

void setMaterialSet (int setId)
 Sets the material set. More...

void setModel (CalModel *pModel)
 Sets the model. More...

void disableInternalData ()
 Disable internal data (and thus springs system).

CalMorphTargetMixergetMorphTargetMixer ()
 Returns the morph target mixer. More...


Protected Attributes

CalModelm_pModel
CalCoreMeshm_pCoreMesh
CalMorphTargetMixerm_pMorphTargetMixer
std::vector< CalSubmesh * > m_vectorSubmesh


Detailed Description

The mesh class.


Constructor & Destructor Documentation

CalMesh::CalMesh  
 

Constructs the mesh instance.

This function is the default constructor of the mesh instance.

CalMesh::~CalMesh   [virtual]
 

Destructs the mesh instance.

This function is the destructor of the mesh instance.


Member Function Documentation

bool CalMesh::create CalCoreMesh   pCoreMesh
 

Creates the mesh instance.

This function creates the mesh instance based on a core mesh.

Parameters:
pCoreMesh  A pointer to the core mesh on which this mesh instance should be based on.
Returns:
One of the following values:
  • true if successful
  • false if an error happend

void CalMesh::destroy  
 

Destroys the mesh instance.

This function destroys all data stored in the mesh instance and frees all allocated memory.

CalCoreMesh * CalMesh::getCoreMesh  
 

Provides access to the core mesh.

This function returns the core mesh on which this mesh instance is based on.

Returns:
One of the following values:
  • a pointer to the core mesh
  • 0 if an error happend

CalMorphTargetMixer * CalMesh::getMorphTargetMixer  
 

Returns the morph target mixer.

This function returns the morph target mixer of the mesh instance.

Returns:
A reference to the morph target mixer.

CalSubmesh * CalMesh::getSubmesh int    id
 

Provides access to a submesh.

This function returns the submesh with the given ID.

Parameters:
id  The ID of the submesh that should be returned.
Returns:
One of the following values:
  • a pointer to the submesh
  • 0 if an error happend

int CalMesh::getSubmeshCount  
 

Returns the number of submeshes.

This function returns the number of submeshes in the mesh instance.

Returns:
The number of submeshes.

std::vector< CalSubmesh * > & CalMesh::getVectorSubmesh  
 

Returns the submesh vector.

This function returns the vector that contains all submeshes of the mesh instance.

Returns:
A reference to the submesh vector.

void CalMesh::setLodLevel float    lodLevel
 

Sets the LOD level.

This function sets the LOD level of the mesh instance.

Parameters:
lodLevel  The LOD level in the range [0.0, 1.0].

void CalMesh::setMaterialSet int    setId
 

Sets the material set.

This function sets the material set of the mesh instance.

Parameters:
setId  The ID of the material set.

void CalMesh::setModel CalModel   pModel
 

Sets the model.

This function sets the model to which the mesh instance is attached to.

Parameters:
pModel  The model to which the mesh instance should be attached to.


The documentation for this class was generated from the following files:
Generated at Sun Oct 12 18:38:49 2003 by The Cal3D Team with doxygen 1.2.14 © 1997-2001 Dimitri van Heesch