15 #ifndef DAECHARACTER_H
16 #define DAECHARACTER_H
18 #include "pandatoolbase.h"
19 #include "typedReferenceCount.h"
20 #include "typeHandle.h"
24 #include "pre_fcollada_include.h"
26 #include "FCDocument/FCDSceneNode.h"
27 #include "FCDocument/FCDControllerInstance.h"
28 #include "FCDocument/FCDSkinController.h"
29 #include "FCDocument/FCDGeometryMesh.h"
42 INLINE
Joint(
EggGroup *group,
const FCDSceneNode *scene_node) :
44 _scene_node(scene_node),
50 const FCDSceneNode *_scene_node;
53 typedef epvector<Joint> Joints;
69 const FCDGeometryMesh *_skin_mesh;
70 const FCDControllerInstance *_instance;
75 const FCDSkinController *_skin_controller;
81 return get_class_type();
83 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
87 static void init_type() {
88 TypedReferenceCount::init_type();
89 register_type(_type_handle,
"DaeCharacter",
90 TypedReferenceCount::get_class_type());
This is a 4-by-4 transform matrix.
void r_collect_keys(FCDSceneNode *node, pset< float > &keys)
Collects all animation keys found for the given node tree.
A base class for things which need to inherit from both TypedObject and from ReferenceCount.
Class representing an animated character.
This class supervises the construction of an EggData structure from a DAE file.
The main glue of the egg hierarchy, this corresponds to the <Group>, <Instance>, and <Joint> type nod...
void influence_vertex(int index, EggVertex *vertex)
Adds the influences for the given vertex.
static const LMatrix4d & ident_mat()
Returns an identity matrix.
Any one-, two-, three-, or four-component vertex, possibly with attributes such as a normal...
void bind_joints(JointMap &joint_map)
Binds the joints to the character.
This is our own Panda specialization on the default STL set.
TypeHandle is the identifier used to differentiate C++ class types.
void build_table(EggTable *parent, FCDSceneNode *node, const pset< float > &keys)
Processes a joint node and its transforms.
void collect_keys(pset< float > &keys)
Collects all animation keys of animations applied to this character.
void adjust_joints(FCDSceneNode *node, const JointMap &joint_map, const LMatrix4d &transform=LMatrix4d::ident_mat())
Traverses through the character hierarchy in order to bind the mesh to the character.