15 #include "characterJointBundle.h"
17 #include "datagramIterator.h"
18 #include "bamReader.h"
19 #include "bamWriter.h"
30 CharacterJointBundle::
31 CharacterJointBundle(
const string &name) :
PartBundle(name) {
39 CharacterJointBundle::
40 ~CharacterJointBundle() {
62 void CharacterJointBundle::
64 PartBundle::add_node(node);
65 if (node->
is_of_type(Character::get_class_type())) {
67 r_set_character(
this, character);
80 void CharacterJointBundle::
82 PartBundle::remove_node(node);
97 void CharacterJointBundle::
105 if (group->
is_of_type(CharacterJoint::get_class_type())) {
109 Children::const_iterator ci;
110 for (ci = group->_children.begin(); ci != group->_children.end(); ++ci) {
111 r_set_character((*ci), character);
127 parse_params(params, scan, manager);
128 me->fillin(scan, manager);
The collection of all the joints and sliders in the character.
This is the fundamental interface for extracting binary objects from a Bam file, as generated by a Ba...
An animated character, with skeleton-morph animation and either soft-skinned or hard-skinned vertices...
Base class for objects that can be written to and read from Bam files.
bool is_of_type(TypeHandle handle) const
Returns true if the current object is or derives from the indicated type.
static TypedWritable * make_CharacterJointBundle(const FactoryParams ¶ms)
Factory method to generate a CharacterJointBundle object.
Character * get_node(int n) const
Returns the nth Character associated with this PartBundle.
This is a node that contains a pointer to an PartBundle.
An instance of this class is passed to the Factory when requesting it to do its business and construc...
void register_finalize(TypedWritable *whom)
Should be called by an object reading itself from the Bam file to indicate that this particular objec...
static void register_with_read_factory()
Factory method to generate a CharacterJointBundle object.
void register_factory(TypeHandle handle, CreateFunc *func)
Registers a new kind of thing the Factory will be able to create.
static WritableFactory * get_factory()
Returns the global WritableFactory for generating TypedWritable objects.
This is the root of a MovingPart hierarchy.
This represents one joint of the character's animation, containing an animating transform matrix...
int get_num_nodes() const
Returns the number of PartBundleNodes that contain a pointer to this PartBundle.
A class to retrieve the individual data elements previously stored in a Datagram. ...
TypeHandle is the identifier used to differentiate C++ class types.
This is the base class for PartRoot and MovingPart.