# cGELMesh Class Reference
[Module - GEL Dynamics Engine (Deformable Body Simulation)]

cGELMesh inherits from cMesh and integrate a skeleton model for deformation simulation. More...

`#include <CGELMesh.h>`

Inheritance diagram for cGELMesh:

[legend]

List of all members.

## Public Member Functions
| cGELMesh (cWorld *a_world)
| Constructor of cMesh.
virtual | ~cGELMesh ()
| Destructor of cMesh.
void | buildVertices ()
| Build dynamic vertices for deformable mesh.
void | connectVerticesToSkeleton (bool a_connectToNodesOnly)
| Connect each vertex to skeleton.
void | updateVertexPosition ()
| Update position of vertices connected to skeleton.
void | clearForces ()
| Clear forces.
void | clearExternalForces ()
| Clear external forces.
void | computeForces ()
| Compute forces.
void | computeNextPose (double iTimeInterval)
| Compute next pose.
void | applyNextPose ()
| Apply new computed pose.
virtual void | render (const int a_renderMode=CHAI_RENDER_MODE_RENDER_ALL)
| Render deformable mesh.
## Public Attributes
list< cGELSkeletonNode * > | m_nodes
| List of nodes composing the skeleton.
list< cGELSkeletonLink * > | m_links
| List of links connecting the different nodes.
list< cGELLinearSpring * > | m_linearSprings
| List of linear springs connecting vertices together.
vector< cGELVertex > | m_gelVertices
| List of deformable vertices.
bool | m_showSkeletonModel
| If true then display skeleton.
bool | m_showMassParticleModel
| If true then display mass particle model.
bool | m_useSkeletonModel
| Use skeleton model.
bool | m_useMassParticleModel
| Use vertex mass particle model.

## Detailed Description

cGELMesh inherits from cMesh and integrate a skeleton model for deformation simulation.

## Member Function Documentation

void cGELMesh::applyNextPose | ( |  | ) |

Apply new computed pose.

Apply the next pose of each node.

void cGELMesh::buildVertices | ( |  | ) |

Build dynamic vertices for deformable mesh.

Build dynamic vertices for deformable mesh

void cGELMesh::clearExternalForces | ( |  | ) |

Clear external forces.

Clear external forces on nodes.

void cGELMesh::computeForces | ( |  | ) |

Compute forces.

Compute all internal forces.

void cGELMesh::computeNextPose | ( | double | a_timeInterval | ) |

Compute next pose.

Compute next pose of each node.

void cGELMesh::connectVerticesToSkeleton | ( | bool | a_connectToNodesOnly | ) |

Connect each vertex to skeleton.

Connect each vertex to nearest node.

Parameters:

  | a_connectToNodesOnly | if true, then skin is only connected to nodes. otherwise skin shall be connected to links too.

void cGELMesh::render | ( | const int | a_renderMode = `CHAI_RENDER_MODE_RENDER_ALL` | ) | `[virtual]`

Render deformable mesh.

Render this deformable mesh in OpenGL.

Parameters:

  | a_renderMode | Rendering mode (see cGenericObject).

Reimplemented from cMesh.

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

- D:/CHAI3D/build-2-0-0/2.0.0/win32/modules/GEL/CGELMesh.h
- D:/CHAI3D/build-2-0-0/2.0.0/win32/modules/GEL/CGELMesh.cpp

CHAI3D 2.0.0 documentation
Please address any questions to support@chai3d.org
(C) 2003-2009 - CHAI 3D
All Rights Reserved.