My Project
Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Friends | List of all members
ParaEngine::CParaXModel Class Reference

ParaX model is the model file for character animation, etc in the game world. More...

#include <ParaXModel.h>

Inheritance diagram for ParaEngine::CParaXModel:
ParaEngine::IAttributeFields ParaEngine::IObject ParaEngine::CRefCounted

Public Types

enum  RENDER_METHOD { SOFT_ANIM = 0, SHADER_ANIM, NO_ANIM, BMAX_MODEL }
 in what method to render the mesh More...
 
- Public Types inherited from ParaEngine::IAttributeFields
typedef ParaEngine::weak_ptr< IObject, IAttributeFieldsWeakPtr_type
 
- Public Types inherited from ParaEngine::IObject
typedef ParaEngine::weak_ptr< IObjectWeakPtr_type
 

Public Member Functions

 CParaXModel (const ParaXHeaderDef &xheader)
 
virtual int GetAttributeClassID ()
 attribute class ID should be identical, unless one knows how overriding rules work. More...
 
virtual const char * GetAttributeClassName ()
 a static string, describing the attribute class object's name
 
virtual const char * GetAttributeClassDescription ()
 a static string, describing the attribute class object
 
virtual int InstallFields (CAttributeClass *pClass, bool bOverride)
 this class should be implemented if one wants to add new attribute. More...
 
virtual int GetChildAttributeColumnCount ()
 we support multi-dimensional child object. More...
 
virtual IAttributeFieldsGetChildAttributeObject (const std::string &sName)
 get attribute by child object. More...
 
virtual int GetChildAttributeObjectCount (int nColumnIndex=0)
 get the number of child objects (row count) in the given column. More...
 
virtual IAttributeFieldsGetChildAttributeObject (int nRowIndex, int nColumnIndex=0)
 
 ATTRIBUTE_METHOD1 (CParaXModel, DumpTextureUsage_s, const char **)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetPolyCount_s, int *)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetPhysicsCount_s, int *)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetGeosetsCount_s, int *)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetRenderPassesCount_s, int *)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetObjectNum_s, void **)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetVertices_s, void **)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetRenderPasses_s, void **)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetGeosets_s, void **)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetIndices_s, void **)
 
 ATTRIBUTE_METHOD1 (CParaXModel, GetAnimations_s, void **)
 
 ATTRIBUTE_METHOD1 (CParaXModel, SaveToDisk_s, char *)
 
int GetPolyCount ()
 get polycount of this mesh object
 
int GetPhysicsCount ()
 get physics polycount of this mesh object
 
const char * DumpTextureUsage ()
 get texture usage such as the number of textures and their sizes. More...
 
const ParaXModelObjNumGetObjectNum () const
 get the number of objects in the model. More...
 
const ParaXHeaderDefGetHeader () const
 
bool CheckMinVersion (int v0, int v1=0, int v2=0, int v3=0)
 check the minimum file version. More...
 
void initVertices (int nVertices, ModelVertex *pVertices)
 file loading for ParaX file type More...
 
void initIndices (int nIndices, uint16 *pIndices)
 
void initTranslucentFaceGroups ()
 call this function only once after the model data is loaded. More...
 
ModelAttachmentNewAttachment (bool bOverwrite, int nAttachmentID, int nBoneIndex, const Vector3 &pivotPoint)
 create new attachment
 
bool IsValid ()
 whether this is a valid model
 
bool InitDeviceObjects ()
 TODO: currently this is not implemented.
 
bool DeleteDeviceObjects ()
 TODO: currently this is not implemented.
 
bool SetupTransformByID (int nID)
 set the transform matrix for the specified attachment ID on this model. More...
 
void drawModel (SceneState *pSceneState, CParameterBlock *pMaterialParam=NULL, int nRenderMethod=-1)
 
void animate (SceneState *pSceneState, CharacterPose *pPose, IAttributeFields *pAnimInstance=NULL)
 animate the entire model according to the current animation and blending settings. More...
 
void draw (SceneState *pSceneState, CParameterBlock *materialParams=NULL, int nRenderMethod=-1)
 render the model, according to the current animation states. More...
 
void BuildShadowVolume (ShadowVolume *pShadowVolume, LightParams *pLight, Matrix4 *mxWorld)
 Build Shadow Volume.
 
void updateEmitters (SceneState *pSceneState, float dt)
 
void drawBones ()
 
void drawBoundingVolume ()
 
void calcBones (CharacterPose *pPose, const AnimIndex &CurrentAnim, const AnimIndex &BlendingAnim, float blendingFactor, IAttributeFields *pAnimInstance=NULL)
 calc all Bones in the model with motion blending with a specified blending frame. More...
 
void calcBones ()
 for model without animations, but with bones. More...
 
void PostCalculateBoneMatrix (uint32 nBones)
 
Matrix4GetAttachmentMatrix (Matrix4 *pOut, int nAttachmentID, const AnimIndex &CurrentAnim, const AnimIndex &BlendingAnim, float blendingFactor, bool bRecalcBone=true, IAttributeFields *pAnimInstance=NULL)
 calculate only specified bone in the attachment, all parent bones will also be calculated in order to get the matrix for the specified bone. More...
 
bool HasAttachmentMatrix (int nAttachmentID)
 whether we have attachment matrix. More...
 
Vector3 GetWeightedVertexByIndex (unsigned short nIndex)
 
void lightsOn (uint32 lbase)
 
void lightsOff (uint32 lbase)
 
bool HasAnimation ()
 return true if the model has animation. More...
 
bool IsBmaxModel ()
 whether it is bmax model with vertex color. More...
 
void SetBmaxModel ()
 
void LoadTextures ()
 load textures
 
AnimIndex GetAnimIndexByID (int nAnimID)
 return the animation index by animation ID. More...
 
int GetAnimIDByIndex (int nAnimIndex)
 return the ID of the animation at the specified index. More...
 
const ModelAnimationGetModelAnimByIndex (int nAnimIndex)
 return NULL if not exist
 
float GetBoundingRadius ()
 get the mesh radius
 
bool canAttach (int id)
 whether the model has a specified attachment point
 
void RenderNoAnim (SceneState *pSceneState)
 
void RenderSoftAnim (SceneState *pSceneState, CParameterBlock *pMaterialParams=NULL)
 
void RenderSoftNoAnim (SceneState *pSceneState, CParameterBlock *pMaterialParams=NULL)
 
void RenderShaderAnim (SceneState *pSceneState)
 
void RenderBMaxModel (SceneState *pSceneState, CParameterBlock *pMaterialParams=NULL)
 
void DrawPass (ModelRenderPass &p)
 only called inside Render* function
 
void DrawPass_NoAnim (ModelRenderPass &p)
 
void DrawPass_NoAnim_VB (ModelRenderPass &p, size_t start)
 
void DrawPass_BMax_VB (ModelRenderPass &p, size_t start)
 
void DrawPass_BMax (ModelRenderPass &p)
 
void ClearFaceGroups ()
 clear all face groups. More...
 
bool HasAlphaBlendedObjects ()
 
int GetNextPhysicsGroupID (int nPhysicsGroup=-1)
 return the physics group id that is closest to nPhysicsGroup. More...
 
HRESULT ClonePhysicsMesh (DWORD *pNumVertices, Vector3 **ppVerts, DWORD *pNumTriangles, DWORD **ppIndices, int *pnMeshPhysicsGroup=NULL, int *pnTotalMeshGroupCount=NULL)
 Get the physics mesh in terms of vertices and indices. More...
 
void SaveToDisk (const char *path)
 
void SetRenderMethod (RENDER_METHOD method)
 
void SetVertexBufferDirty ()
 
- Public Member Functions inherited from ParaEngine::IAttributeFields
 ATTRIBUTE_METHOD1 (IAttributeFields, GetName_s, const char **)
 
 ATTRIBUTE_METHOD1 (IAttributeFields, SetName_s, const char *)
 
 ATTRIBUTE_METHOD (IAttributeFields, PrintObject_s)
 
 ATTRIBUTE_METHOD (IAttributeFields, AddRef_s)
 
 ATTRIBUTE_METHOD1 (IAttributeFields, GetRefCount_s, int *)
 
 ATTRIBUTE_METHOD1 (IAttributeFields, SetTime_s, int)
 
 ATTRIBUTE_METHOD1 (IAttributeFields, GetTime_s, int *)
 
 ATTRIBUTE_METHOD (IAttributeFields, Release_s)
 
virtual const std::string & GetIdentifier ()
 
virtual void SetIdentifier (const std::string &sID)
 
virtual bool IsModified ()
 whether some of the fields are modified.It is up to the implementation class to provide this functionality if necessary. More...
 
virtual void SetModified (bool bModified)
 set whether any field has been modified. More...
 
virtual bool ValidateFields ()
 validate all fields and return true if validation passed. More...
 
virtual string GetValidationMessage ()
 get the recent validation message due to the most recent call to ValidateFields()
 
virtual bool ResetField (int nFieldID)
 Reset the field to its initial or default value. More...
 
virtual bool InvokeEditor (int nFieldID, const std::string &sParameters)
 Invoke an (external) editor for a given field. More...
 
virtual bool AddChildAttributeObject (IAttributeFields *pChild, int nRowIndex=-1, int nColumnIndex=0)
 add child object. More...
 
virtual void * QueryObjectByName (const std::string &sObjectType)
 convert to object of a given type. More...
 
virtual void * QueryObject (int nObjectType)
 convert to object of a given type. More...
 
virtual int GetTime ()
 get the current local time in case it is animated in milli seconds frames. More...
 
virtual void SetTime (int nTime)
 
virtual CDynamicAttributeFieldGetDynamicField (const std::string &sName)
 Get a dynamic field with a given name. More...
 
virtual CDynamicAttributeFieldGetDynamicField (int nIndex)
 Get a dynamic field with a given index. More...
 
virtual const char * GetDynamicFieldNameByIndex (int nIndex)
 get field name by index
 
virtual int GetDynamicFieldCount ()
 how many dynamic field this object currently have. More...
 
virtual int SetDynamicField (const std::string &sName, const CVariable &value)
 set a dynamic field with a given name. More...
 
virtual int AddDynamicField (const std::string &sName, ATTRIBUTE_FIELDTYPE dwType)
 add dynamic field and return field index
 
virtual void RemoveAllDynamicFields ()
 remove all dynamic fields
 
virtual int SaveDynamicFieldsToString (std::string &output)
 save only text dynamic fields to fieldname = value text strings. More...
 
virtual int LoadDynamicFieldsFromString (const std::string &input)
 load only text dynamic fields from string More...
 
CAttributeClassGetAttributeClass ()
 get the main attribute class object. More...
 
void PrintObject ()
 print the content of this object to a text file at temp/doc/[ClassName].txt. More...
 
- Public Member Functions inherited from ParaEngine::IObject
virtual void Clone (IObject *obj) const
 Clone the object's contains to a pointer. More...
 
virtual IObjectClone () const
 Clone the object's contains and return a pointer to the newly created object. More...
 
virtual bool Equals (const IObject *obj) const
 Compare the object with another object. More...
 
virtual const ITypeGetType () const
 
virtual std::string ToString () const
 
WeakPtr_typeGetWeakReference ()
 get weak reference object. More...
 
virtual int ProcessObjectEvent (const ObjectEvent &event)
 this function is only used to backward compatibility of ParaObject:AddEvent() function. More...
 
- Public Member Functions inherited from ParaEngine::CRefCounted
void addref () const
 add reference count of the object. More...
 
bool delref () const
 decrease reference count of the object. More...
 
int GetRefCount () const
 get the reference count
 
virtual int Release ()
 
CRefCountedAddToAutoReleasePool ()
 addref and releases the ownership sometime soon automatically (usually at the end of the current frame). More...
 

Public Attributes

ParaXHeaderDef m_header
 model header
 
ParaXModelObjNum m_objNum
 object counts
 
float m_radius
 bounding radius
 
int m_nHasAlphaBlendedRenderPass
 -1 uninitialized. More...
 
RENDER_METHOD m_RenderMethod
 
ModelAnimationanims
 animation info for the current model
 
ParaVertexBuffer m_pVertexBuffer
 vertex buffer for skinned vertex
 
ParaIndexBuffer m_pIndexBuffer
 index buffer
 
size_t vbufsize
 
bool animated: 1
 
bool animGeometry: 1
 
bool animTextures: 1
 
bool animBones: 1
 
bool animTexRGB: 1
 
bool rotatePartice2SpeedVector: 1
 
bool forceAnim: 1
 
TextureAnimtexanims
 
int * globalSequences
 
ModelColorcolors
 
ModelTransparencytransparency
 
ModelLightlights
 
ParticleSystemparticleSystems
 
RibbonEmitterribbons
 
ModelVertexm_origVertices
 
int * m_frame_number_vertices
 this always contains the same number of items as m_origVertices. More...
 
int m_nCurrentFrameNumber
 
Vector3m_vertices
 
Vector3m_normals
 
Vector2texcoords1
 
uint16 * m_indices
 
Vector3bounds
 
uint16 * boundTris
 
ModelCamera cam
 
Bonebones
 
asset_ptr< TextureEntity > * textures
 
std::vector< ModelRenderPasspasses
 
std::vector< int > m_TranslucentPassIndice
 it has the same number of element as the passes. More...
 
std::vector< CFaceGroup * > m_faceGroups
 translucent face groups. More...
 
std::vector< ModelGeosetgeosets
 
bool * showGeosets
 a list of face group
 
int specialTextures [MAX_MODEL_TEXTURES]
 
TextureEntityreplaceTextures [MAX_MODEL_TEXTURES]
 
bool useReplaceTextures [MAX_MODEL_TEXTURES]
 
AnimIndex m_CurrentAnim
 current animation index, this is different from sequence ID an absolute ParaX frame number denoting the current animation frame. More...
 
AnimIndex m_NextAnim
 the next animation index.if it is -1, the next animation will depends on the loop property of the current sequenc; otherwise, the animation specified by the ID will be played next, after the current animation reached the end. More...
 
AnimIndex m_BlendingAnim
 the animation sequence with which the current animation should be blended. More...
 
float blendingFactor
 by how much the blending frame should be blended with the current frame. More...
 
float fBlendingTime
 blending time in seconds
 
bool m_bIsValid
 
bool hasCamera
 
bool m_bTextureLoaded
 
float m_trans
 
std::vector< ModelAttachmentm_atts
 
int m_attLookup [MAX_MODEL_ATTACHMENTS]
 
Vector3 m_vNeckYawAxis
 default to unitY
 
Vector3 m_vNeckPitchAxis
 default to unitZ
 
int m_boneLookup [MAX_KNOWN_BONE_NODE]
 a mapping from known bone id to bone index. More...
 

Static Public Attributes

static const int MAX_MODEL_TEXTURES = 32
 max number of textures per model
 
static const int MAX_MODEL_ATTACHMENTS = 40
 max number of attachment points per model
 
static CEffectFilem_pEffectFile = NULL
 The effect file entity used to render the animated model.
 
static VertexDeclarationPtr m_pVertexDeclaration = NULL
 vertex declaration used in the vertex shader of the effect file
 

Friends

struct ModelRenderPass
 

Additional Inherited Members

- Static Public Member Functions inherited from ParaEngine::IAttributeFields
static HRESULT GetAttributeClassID_s (IAttributeFields *cls, int *p1)
 
static HRESULT GetAttributeClassName_s (IAttributeFields *cls, const char **p1)
 
static bool OpenWithDefaultEditor (const char *sFilename, bool bWaitOnReturn=false)
 Open a given file with the default registered editor in the game engine. More...
 
- Protected Member Functions inherited from ParaEngine::IAttributeFields
virtual CAttributeClassCreateAttributeClass ()
 initialize fields
 
virtual CDynamicAttributesSetGetDynamicAttributes (bool bCreateIfNotExist=false)
 
- Protected Attributes inherited from ParaEngine::IObject
WeakPtr_type m_weak_reference
 
- Protected Attributes inherited from ParaEngine::CRefCounted
int m_refcount
 

Detailed Description

ParaX model is the model file for character animation, etc in the game world.

Member Enumeration Documentation

§ RENDER_METHOD

in what method to render the mesh

Enumerator
SOFT_ANIM 

using software skinning

SHADER_ANIM 

using hardware skinning, need vertex shader 1.1 or later

NO_ANIM 

render without animation.

It is just a solid mesh.

BMAX_MODEL 

BMAX model color model.

Member Function Documentation

§ animate()

void CParaXModel::animate ( SceneState pSceneState,
CharacterPose pPose,
IAttributeFields pAnimInstance = NULL 
)

animate the entire model according to the current animation and blending settings.

Parameters
pPoseit will override the poses defined in the model.:

§ calcBones() [1/2]

void CParaXModel::calcBones ( CharacterPose pPose,
const AnimIndex CurrentAnim,
const AnimIndex BlendingAnim,
float  blendingFactor,
IAttributeFields pAnimInstance = NULL 
)

calc all Bones in the model with motion blending with a specified blending frame.

Parameters
pPoseit will override the poses defined in the model.
nCurrentAnimcurrent animation sequence ID
currentFramean absolute ParaX frame number denoting the current animation frame. It is always within the range of the current animation sequence's start and end frame number.
nBlendingAnimthe animation sequence with which the current animation should be blended.
blendingFramean absolute ParaX frame number denoting the blending animation frame. It is always within the range of the blending animation sequence's start and end frame number.
blendingFactorby how much the blending frame should be blended with the current frame. 1.0 will use solely the blending frame, whereas 0.0 will use only the current frame. [0,1), blendingFrame*(blendingFactor)+(1-blendingFactor)*currentFrame

§ calcBones() [2/2]

void CParaXModel::calcBones ( )

for model without animations, but with bones.

§ CheckMinVersion()

bool CParaXModel::CheckMinVersion ( int  v0,
int  v1 = 0,
int  v2 = 0,
int  v3 = 0 
)

check the minimum file version.

Return true if file version is equal or higher than the given one.

§ ClearFaceGroups()

void CParaXModel::ClearFaceGroups ( )

clear all face groups.

§ ClonePhysicsMesh()

HRESULT CParaXModel::ClonePhysicsMesh ( DWORD *  pNumVertices,
Vector3 **  ppVerts,
DWORD *  pNumTriangles,
DWORD **  ppIndices,
int *  pnMeshPhysicsGroup = NULL,
int *  pnTotalMeshGroupCount = NULL 
)

Get the physics mesh in terms of vertices and indices.

Parameters
pNumVertices[out] number of vertices
ppVerts[out] buffer contains all vertices. The caller needs to release the buffer using delete [] buffer.
pNumTriangles[out] number of triangles, each triangle has three indices. Please note that if the mesh contains no physics faces, the pNumTriangles is 0. However pNumVertices might be positive.
ppIndices[out] buffer contains all indices. The caller needs to release the buffer using delete [] buffer.
nMeshPhysicsGroup[in|out]: the mesh physics group to get. On return it will be assigned with the next mesh group.
Returns
S_OK, if succeed.

§ draw()

void CParaXModel::draw ( SceneState pSceneState,
CParameterBlock materialParams = NULL,
int  nRenderMethod = -1 
)

render the model, according to the current animation states.

make sure to call animate before calling this functions.

assume that the animate() function has already been called to set the bone matrices

§ drawModel()

void CParaXModel::drawModel ( SceneState pSceneState,
CParameterBlock pMaterialParam = NULL,
int  nRenderMethod = -1 
)

apply surface materials

§ DumpTextureUsage()

const char * CParaXModel::DumpTextureUsage ( )

get texture usage such as the number of textures and their sizes.

§ GetAnimIDByIndex()

int CParaXModel::GetAnimIDByIndex ( int  nAnimIndex)

return the ID of the animation at the specified index.

if there is no animation at the index, 0 (default animation ID) is returned.

§ GetAnimIndexByID()

AnimIndex CParaXModel::GetAnimIndexByID ( int  nAnimID)

return the animation index by animation ID.

the animation <ID, name> pairs are stored in the AnimDB table. if the animation ID is not found, 0 (usually the stand animation) is returned. a sequential search is used for the specified animation. Below is some common mappings. <0, stand> <1, death> <2, spell> <3, stop> <4, walk> <5, run> : return index of the animation. If the animation is not found, then -1 is returned.

§ GetAttachmentMatrix()

Matrix4 * CParaXModel::GetAttachmentMatrix ( Matrix4 pOut,
int  nAttachmentID,
const AnimIndex CurrentAnim,
const AnimIndex BlendingAnim,
float  blendingFactor,
bool  bRecalcBone = true,
IAttributeFields pAnimInstance = NULL 
)

calculate only specified bone in the attachment, all parent bones will also be calculated in order to get the matrix for the specified bone.

Parameters
pOutthe bone transform matrix.
nAttachmentIDthe bone index.
bRecalcBonewhether we will recalculate bone chains according to the current animation pose.
Returns
: NULL if not successful, otherwise it is pOut.

calculate the bone and its parent bones

§ GetAttributeClassID()

virtual int ParaEngine::CParaXModel::GetAttributeClassID ( )
inlinevirtual

attribute class ID should be identical, unless one knows how overriding rules work.

Reimplemented from ParaEngine::IAttributeFields.

§ GetChildAttributeColumnCount()

int CParaXModel::GetChildAttributeColumnCount ( )
virtual

we support multi-dimensional child object.

by default objects have only one column.

Reimplemented from ParaEngine::IAttributeFields.

§ GetChildAttributeObject()

IAttributeFields * CParaXModel::GetChildAttributeObject ( const std::string &  sName)
virtual

get attribute by child object.

used to iterate across the attribute field hierarchy.

Reimplemented from ParaEngine::IAttributeFields.

§ GetChildAttributeObjectCount()

int CParaXModel::GetChildAttributeObjectCount ( int  nColumnIndex = 0)
virtual

get the number of child objects (row count) in the given column.

please note different columns can have different row count.

Reimplemented from ParaEngine::IAttributeFields.

§ GetNextPhysicsGroupID()

int CParaXModel::GetNextPhysicsGroupID ( int  nPhysicsGroup = -1)

return the physics group id that is closest to nPhysicsGroup.

or -1 if there is none.

§ GetObjectNum()

const ParaXModelObjNum& ParaEngine::CParaXModel::GetObjectNum ( ) const
inline

get the number of objects in the model.

§ GetWeightedVertexByIndex()

Vector3 CParaXModel::GetWeightedVertexByIndex ( unsigned short  nIndex)
inline
Parameters
nIndexthe index into the global indices.

§ HasAnimation()

bool CParaXModel::HasAnimation ( )

return true if the model has animation.

§ HasAttachmentMatrix()

bool CParaXModel::HasAttachmentMatrix ( int  nAttachmentID)

whether we have attachment matrix.

Parameters
nAttachmentIDthe attachment id.

§ initTranslucentFaceGroups()

void CParaXModel::initTranslucentFaceGroups ( )

call this function only once after the model data is loaded.

It will search for translucent pass and build face groups to store them for later sorting and rendering.

Set the texture

§ initVertices()

void CParaXModel::initVertices ( int  nVertices,
ModelVertex pVertices 
)

file loading for ParaX file type

read m_origVertices

Create vertex buffer with skinning information

NOT USED: Create vertex buffer with only vertex information

§ InstallFields()

int CParaXModel::InstallFields ( CAttributeClass pClass,
bool  bOverride 
)
virtual

this class should be implemented if one wants to add new attribute.

This function is always called internally.

Reimplemented from ParaEngine::IAttributeFields.

§ IsBmaxModel()

bool CParaXModel::IsBmaxModel ( )

whether it is bmax model with vertex color.

§ SetupTransformByID()

bool CParaXModel::SetupTransformByID ( int  nID)

set the transform matrix for the specified attachment ID on this model.

it is assumed that the transform of this model has already been set in the render device hence it will just multiple over the one in the device. return true, if the nID is a valid attachment point on the model.

Member Data Documentation

§ blendingFactor

float ParaEngine::CParaXModel::blendingFactor

by how much the blending frame should be blended with the current frame.

1.0 will use solely the blending frame, whereas 0.0 will use only the current frame. [0,1), blendingFrame*(blendingFactor)+(1-blendingFactor)*currentFrame

§ m_BlendingAnim

AnimIndex ParaEngine::CParaXModel::m_BlendingAnim

the animation sequence with which the current animation should be blended.

an absolute ParaX frame number denoting the blending animation frame. It is always within the range of the blending animation sequence's start and end frame number.

§ m_boneLookup

int ParaEngine::CParaXModel::m_boneLookup[MAX_KNOWN_BONE_NODE]

a mapping from known bone id to bone index.

§ m_CurrentAnim

AnimIndex ParaEngine::CParaXModel::m_CurrentAnim

current animation index, this is different from sequence ID an absolute ParaX frame number denoting the current animation frame.

It is always within the range of the current animation sequence's start and end frame number.

§ m_faceGroups

std::vector<CFaceGroup*> ParaEngine::CParaXModel::m_faceGroups

translucent face groups.

§ m_frame_number_vertices

int* ParaEngine::CParaXModel::m_frame_number_vertices

this always contains the same number of items as m_origVertices.

it stores the frame number that a certain vertices are used. This avoids the same vertex to be calculated multiple times in a single animation pose.

§ m_NextAnim

AnimIndex ParaEngine::CParaXModel::m_NextAnim

the next animation index.if it is -1, the next animation will depends on the loop property of the current sequenc; otherwise, the animation specified by the ID will be played next, after the current animation reached the end.

§ m_nHasAlphaBlendedRenderPass

int ParaEngine::CParaXModel::m_nHasAlphaBlendedRenderPass

-1 uninitialized.

0 false, 1 true.

§ m_TranslucentPassIndice

std::vector<int> ParaEngine::CParaXModel::m_TranslucentPassIndice

it has the same number of element as the passes.

the int value denotes the index into the m_faceGroups


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