Blender V2.61 - r43446
|
#include <BL_SkinDeformer.h>
Public Member Functions | |
virtual void | Relink (CTR_Map< class CTR_HashedPtr, void * > *map) |
void | SetArmature (class BL_ArmatureObject *armobj) |
BL_SkinDeformer (BL_DeformableGameObject *gameobj, struct Object *bmeshobj, class RAS_MeshObject *mesh, BL_ArmatureObject *arma=NULL) | |
BL_SkinDeformer (BL_DeformableGameObject *gameobj, struct Object *bmeshobj_old, struct Object *bmeshobj_new, class RAS_MeshObject *mesh, bool release_object, bool recalc_normal, BL_ArmatureObject *arma=NULL) | |
virtual RAS_Deformer * | GetReplica () |
virtual void | ProcessReplica () |
virtual | ~BL_SkinDeformer () |
bool | Update (void) |
bool | UpdateInternal (bool shape_applied) |
bool | Apply (class RAS_IPolyMaterial *polymat) |
bool | UpdateBuckets (void) |
bool | PoseUpdated (void) |
void | ForceUpdate () |
virtual bool | ShareVertexArray () |
Protected Member Functions | |
void | BlenderDeformVerts () |
void | BGEDeformVerts () |
Protected Attributes | |
BL_ArmatureObject * | m_armobj |
float | m_time |
double | m_lastArmaUpdate |
float | m_obmat [4][4] |
bool | m_releaseobject |
bool | m_poseApplied |
bool | m_recalcNormal |
bool | m_copyNormals |
struct bPoseChannel ** | m_dfnrToPC |
Definition at line 51 of file BL_SkinDeformer.h.
BL_SkinDeformer::BL_SkinDeformer | ( | BL_DeformableGameObject * | gameobj, |
struct Object * | bmeshobj, | ||
class RAS_MeshObject * | mesh, | ||
BL_ArmatureObject * | arma = NULL |
||
) |
Definition at line 69 of file BL_SkinDeformer.cpp.
References copy_m4_m4(), m_obmat, and Object::obmat.
Referenced by GetReplica().
BL_SkinDeformer::BL_SkinDeformer | ( | BL_DeformableGameObject * | gameobj, |
struct Object * | bmeshobj_old, | ||
struct Object * | bmeshobj_new, | ||
class RAS_MeshObject * | mesh, | ||
bool | release_object, | ||
bool | recalc_normal, | ||
BL_ArmatureObject * | arma = NULL |
||
) |
Definition at line 87 of file BL_SkinDeformer.cpp.
References copy_m4_m4(), m_obmat, and Object::obmat.
BL_SkinDeformer::~BL_SkinDeformer | ( | ) | [virtual] |
Definition at line 112 of file BL_SkinDeformer.cpp.
References m_armobj, m_dfnrToPC, m_releaseobject, and CValue::Release().
bool BL_SkinDeformer::Apply | ( | class RAS_IPolyMaterial * | polymat | ) | [virtual] |
Reimplemented from BL_MeshDeformer.
Reimplemented in BL_ModifierDeformer.
Definition at line 134 of file BL_SkinDeformer.cpp.
References RAS_MeshSlot::begin(), RAS_MeshSlot::end(), RAS_MeshSlot::iterator::endvertex, RAS_MeshObject::GetMeshMaterial(), RAS_TexVert::getOrigIndex(), i, m_copyNormals, BL_MeshDeformer::m_gameobj, BL_MeshDeformer::m_pMeshObject, RAS_MeshMaterial::m_slots, BL_MeshDeformer::m_transnors, BL_MeshDeformer::m_transverts, RAS_MeshSlot::next(), RAS_MeshObject::NumMaterials(), RAS_TexVert::SetNormal(), RAS_TexVert::SetXYZ(), RAS_MeshSlot::iterator::startvertex, Update(), and RAS_MeshSlot::iterator::vertex.
Referenced by UpdateBuckets().
void BL_SkinDeformer::BGEDeformVerts | ( | ) | [protected] |
Definition at line 215 of file BL_SkinDeformer.cpp.
References BLI_countlist(), BONE_NO_DEFORM, bPoseChannel::chan_mat, co, MDeformWeight::def_nr, Object::defbase, Mesh::dvert, MDeformVert::dw, ListBase::first, bPoseChannel::flag, get_pose_channel(), BL_ArmatureObject::GetArmatureObject(), i, m_armobj, BL_MeshDeformer::m_bmesh, m_copyNormals, m_dfnrToPC, BL_MeshDeformer::m_objMesh, BL_MeshDeformer::m_transnors, BL_MeshDeformer::m_transverts, bDeformGroup::name, bDeformGroup::next, norm(), NULL, Object::pose, Mesh::totvert, MDeformVert::totweight, and MDeformWeight::weight.
Referenced by UpdateInternal().
void BL_SkinDeformer::BlenderDeformVerts | ( | ) | [protected] |
Definition at line 194 of file BL_SkinDeformer.cpp.
References ARM_DEF_VGROUP, armature_deform_verts(), copy_m4_m4(), BL_ArmatureObject::GetArmatureObject(), m_armobj, BL_MeshDeformer::m_bmesh, BL_MeshDeformer::m_objMesh, m_obmat, m_recalcNormal, BL_MeshDeformer::m_transverts, NULL, Object::obmat, BL_MeshDeformer::RecalcNormals(), and Mesh::totvert.
Referenced by UpdateInternal().
void BL_SkinDeformer::ForceUpdate | ( | ) | [inline] |
Reimplemented in BL_ModifierDeformer, and BL_ShapeDeformer.
Definition at line 92 of file BL_SkinDeformer.h.
References m_lastArmaUpdate.
RAS_Deformer * BL_SkinDeformer::GetReplica | ( | void | ) | [virtual] |
Reimplemented from BL_MeshDeformer.
Reimplemented in BL_ModifierDeformer, and BL_ShapeDeformer.
Definition at line 176 of file BL_SkinDeformer.cpp.
References BL_SkinDeformer(), and ProcessReplica().
bool BL_SkinDeformer::PoseUpdated | ( | void | ) | [inline] |
Definition at line 84 of file BL_SkinDeformer.h.
References BL_ArmatureObject::GetLastFrame(), m_armobj, and m_lastArmaUpdate.
Referenced by BL_ShapeDeformer::ExecuteShapeDrivers(), and UpdateInternal().
void BL_SkinDeformer::ProcessReplica | ( | ) | [virtual] |
Reimplemented from BL_MeshDeformer.
Reimplemented in BL_ModifierDeformer, and BL_ShapeDeformer.
Definition at line 186 of file BL_SkinDeformer.cpp.
References m_dfnrToPC, m_lastArmaUpdate, m_releaseobject, and NULL.
Referenced by GetReplica().
void BL_SkinDeformer::Relink | ( | CTR_Map< class CTR_HashedPtr, void * > * | map | ) | [virtual] |
Reimplemented from BL_MeshDeformer.
Definition at line 120 of file BL_SkinDeformer.cpp.
void BL_SkinDeformer::SetArmature | ( | class BL_ArmatureObject * | armobj | ) |
Definition at line 353 of file BL_SkinDeformer.cpp.
References m_armobj.
virtual bool BL_SkinDeformer::ShareVertexArray | ( | ) | [inline, virtual] |
Reimplemented from RAS_Deformer.
Definition at line 96 of file BL_SkinDeformer.h.
bool BL_SkinDeformer::Update | ( | void | ) | [virtual] |
Reimplemented from BL_MeshDeformer.
Reimplemented in BL_ModifierDeformer, and BL_ShapeDeformer.
Definition at line 347 of file BL_SkinDeformer.cpp.
References UpdateInternal().
Referenced by Apply().
bool BL_SkinDeformer::UpdateBuckets | ( | void | ) | [inline, virtual] |
Reimplemented from BL_MeshDeformer.
Definition at line 79 of file BL_SkinDeformer.h.
bool BL_SkinDeformer::UpdateInternal | ( | bool | shape_applied | ) |
Definition at line 305 of file BL_SkinDeformer.cpp.
References BL_ArmatureObject::ApplyPose(), ARM_VDEF_BGE_CPU, ARM_VDEF_BLENDER, BGEDeformVerts(), BlenderDeformVerts(), MVert::co, copy_v3_v3(), BL_ArmatureObject::GetLastFrame(), BL_ArmatureObject::GetVertDeformType(), m_armobj, RAS_Deformer::m_bDynamic, BL_MeshDeformer::m_bmesh, m_lastArmaUpdate, BL_MeshDeformer::m_transnors, BL_MeshDeformer::m_transverts, Mesh::mvert, MVert::no, normal_short_to_float_v3(), PoseUpdated(), BL_ArmatureObject::RestorePose(), Mesh::totvert, and BL_MeshDeformer::VerifyStorage().
Referenced by Update(), and BL_ShapeDeformer::Update().
BL_ArmatureObject* BL_SkinDeformer::m_armobj [protected] |
Definition at line 102 of file BL_SkinDeformer.h.
Referenced by BGEDeformVerts(), BlenderDeformVerts(), BL_ShapeDeformer::ExecuteShapeDrivers(), PoseUpdated(), Relink(), SetArmature(), UpdateInternal(), and ~BL_SkinDeformer().
bool BL_SkinDeformer::m_copyNormals [protected] |
Definition at line 110 of file BL_SkinDeformer.h.
Referenced by Apply(), and BGEDeformVerts().
struct bPoseChannel** BL_SkinDeformer::m_dfnrToPC [protected] |
Definition at line 111 of file BL_SkinDeformer.h.
Referenced by BGEDeformVerts(), ProcessReplica(), and ~BL_SkinDeformer().
double BL_SkinDeformer::m_lastArmaUpdate [protected] |
Definition at line 104 of file BL_SkinDeformer.h.
Referenced by ForceUpdate(), PoseUpdated(), ProcessReplica(), and UpdateInternal().
float BL_SkinDeformer::m_obmat[4][4] [protected] |
Definition at line 106 of file BL_SkinDeformer.h.
Referenced by BL_SkinDeformer(), and BlenderDeformVerts().
bool BL_SkinDeformer::m_poseApplied [protected] |
Definition at line 108 of file BL_SkinDeformer.h.
bool BL_SkinDeformer::m_recalcNormal [protected] |
Definition at line 109 of file BL_SkinDeformer.h.
Referenced by BL_ModifierDeformer::BL_ModifierDeformer(), BlenderDeformVerts(), and BL_ShapeDeformer::Update().
bool BL_SkinDeformer::m_releaseobject [protected] |
Definition at line 107 of file BL_SkinDeformer.h.
Referenced by ProcessReplica(), and ~BL_SkinDeformer().
float BL_SkinDeformer::m_time [protected] |
Definition at line 103 of file BL_SkinDeformer.h.