Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members  

WPCG::WP_AnimatedModel Class Reference

#include <WP_Model.h>

Inheritance diagram for WPCG::WP_AnimatedModel:

WPCG::WP_Model WPCG::WP_Model_MD2 List of all members.

Public Methods

 WP_AnimatedModel (const string &name)
 WP_AnimatedModel (const WP_AnimatedModel &amodel)
virtual ~WP_AnimatedModel ()
WP_AnimatedModel & operator= (const WP_AnimatedModel &amodel)
virtual void drawOpenGL (const WP_Matrix3D &matrix, WP_Object *object)=0
virtual bool initModel ()=0
OPCODE_Model * getCollisionModel (const WP_Object *object)
WP_VertexgetVertex (const WP_Object *object, unsigned int index)
unsigned short getCategoryStartFrame (const string &category)
unsigned short getCategoryNumberFrames (const string &category)
string getCategoryName (unsigned int index) const
unsigned int getNumberCategories () const

Protected Methods

bool finalizeAll ()

Protected Attributes

WP_Frame * frames
unsigned int numberFrames
map< string, WP_FrameCategory * > categories

Detailed Description

this abstract class represents an animated model


Constructor & Destructor Documentation

WPCG::WP_AnimatedModel::WP_AnimatedModel const string &    name [inline]
 

WPCG::WP_AnimatedModel::WP_AnimatedModel const WP_AnimatedModel &    amodel
 

virtual WPCG::WP_AnimatedModel::~WP_AnimatedModel   [inline, virtual]
 


Member Function Documentation

virtual void WPCG::WP_AnimatedModel::drawOpenGL const WP_Matrix3D   matrix,
WP_Object   object
[pure virtual]
 

this function draws the model according to its world matrix into the 3D scene

Parameters:
matrix  a WP_Matrix3D object representing the world matrix of the model indicating where and how the model is rendered into the scene

Implements WPCG::WP_Model.

Implemented in WPCG::WP_Model_MD2.

bool WPCG::WP_AnimatedModel::finalizeAll   [protected, virtual]
 

this function finalizes all after the model was read and everything was initialized. It for instance builds the collision mesh

Implements WPCG::WP_Model.

string WPCG::WP_AnimatedModel::getCategoryName unsigned int    index const [inline]
 

unsigned short WPCG::WP_AnimatedModel::getCategoryNumberFrames const string &    category [inline]
 

unsigned short WPCG::WP_AnimatedModel::getCategoryStartFrame const string &    category [inline]
 

OPCODE_Model* WPCG::WP_AnimatedModel::getCollisionModel const WP_Object   object [inline, virtual]
 

Implements WPCG::WP_Model.

unsigned int WPCG::WP_AnimatedModel::getNumberCategories   const [inline]
 

WP_Vertex* WPCG::WP_AnimatedModel::getVertex const WP_Object   object,
unsigned int    index
[inline, virtual]
 

Implements WPCG::WP_Model.

virtual bool WPCG::WP_AnimatedModel::initModel   [pure virtual]
 

this virtual function should be overriden by child objects. In this function the model must be read and the model's internals must be filled (like for example the meshes, the material etc). Every 3d file format stores this information in a different way there this function can be used to substract the necessary data from it.

Implements WPCG::WP_Model.

Implemented in WPCG::WP_Model_MD2.

WP_AnimatedModel & WPCG::WP_AnimatedModel::operator= const WP_AnimatedModel &    amodel
 


Member Data Documentation

map<string, WP_FrameCategory*> WPCG::WP_AnimatedModel::categories [protected]
 

WP_Frame* WPCG::WP_AnimatedModel::frames [protected]
 

unsigned int WPCG::WP_AnimatedModel::numberFrames [protected]
 


The documentation for this class was generated from the following files:
Generated on Tue Jan 28 20:26:37 2003 by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002