#include <partBundle.h>
Inheritance diagram for PartBundle:
Public Types | |
typedef pmap< AnimControl *, float > | ChannelBlend |
typedef first_of_pair_iterator< ChannelBlend::const_iterator > | control_iterator |
typedef ChannelBlend::size_type | control_size_type |
enum | BlendType { BT_single, BT_linear, BT_normalized_linear } |
enum | HierarchyMatchFlags { HMF_ok_part_extra = 0x01, HMF_ok_anim_extra = 0x02, HMF_ok_wrong_root_name = 0x04 } |
Public Member Functions | |
PartBundle (const string &name="") | |
Normally, a PartBundle constructor should not be called directly--it will get created when a PartBundleNode is created. | |
virtual PartGroup * | make_copy () const |
Allocates and returns a new copy of the node. | |
void | set_blend_type (BlendType bt) |
Defines the way the character responds to multiple set_control_effect()). | |
BlendType | get_blend_type () const |
Returns the way the character responds to multiple animations being bound simultaneously. | |
PartBundleNode * | get_node () const |
Returns the PartBundleNode associated with this PartBundle. | |
void | clear_control_effects () |
Sets the control effect of all AnimControls to zero (but does not "stop" the AnimControls). | |
void | set_control_effect (AnimControl *control, float effect) |
Sets the amount by which the character is affected by the indicated AnimControl (and its associated animation). | |
float | get_control_effect (AnimControl *control) |
Returns the amount by which the character is affected by the indicated AnimControl and its associated animation. | |
virtual void | output (ostream &out) const |
Writes a one-line description of the bundle. | |
virtual void | write (ostream &out, int indent_level) const |
Writes a brief description of the bundle and all of its descendants. | |
PointerTo< AnimControl > | bind_anim (AnimBundle *anim, int hierarchy_match_flags=0) |
Binds the animation to the bundle, if possible, and returns a new AnimControl that can be used to start and stop the animation. | |
bool | bind_anim (AnimBundle *anim, const string &name, int hierarchy_match_flags=0) |
Binds the animation to the bundle, if possible, and returns a new AnimControl that can be used to start and stop the animation. | |
control_iterator | control_begin () const |
Returns an iterator that can be used to traverse the entire set of AnimControls currently in effect. | |
control_iterator | control_end () const |
Returns an iterator that can be used to traverse the entire set of AnimControls currently in effect. | |
control_size_type | control_size () const |
Returns the number of entries between control_begin() and control_end(): the number of AnimControls currently in effect. | |
const ChannelBlend & | get_blend_map () const |
Returns the entire mapping of AnimControls to blend effect. | |
void | advance_time (double time) |
Calls advance_time() on all AnimControls currently in effect. | |
bool | update () |
Updates all the parts in the bundle to reflect the data for the current frame (as set in each of the AnimControls). | |
bool | force_update () |
Updates all the parts in the bundle to reflect the data for the current frame, whether we believe it needs it or not. | |
virtual void | control_activated (AnimControl *control) |
Called by the AnimControl whenever it starts an animation. | |
virtual void | finalize () |
Method to ensure that any necessary clean up tasks that have to be performed by this object are performed. | |
virtual TypeHandle | get_type () const |
virtual TypeHandle | force_init_type () |
PartGroup * | copy_subgraph () const |
Allocates and returns a new copy of this node and of all of its children. | |
int | get_num_children () const |
Returns the number of child nodes of the group. | |
PartGroup * | get_child (int n) const |
Returns the nth child of the group. | |
PartGroup * | find_child (const string &name) const |
Returns the first descendant found with the indicated name, or NULL if no such descendant exists. | |
virtual void | write_with_value (ostream &out, int indent_level) const |
Writes a brief description of the group, showing its current value, and that of all of its descendants. | |
virtual TypeHandle | get_value_type () const |
Returns the TypeHandle associated with the ValueType we are concerned with. | |
void | sort_descendants () |
Sorts the children nodes at each level of the hierarchy into alphabetical order. | |
bool | check_hierarchy (const AnimGroup *anim, const PartGroup *parent, int hierarchy_match_flags=0) const |
Walks the part hierarchy in tandem with the indicated anim hierarchy, and returns true if the hierarchies match, false otherwise. | |
virtual bool | do_update (PartBundle *root, PartGroup *parent, bool parent_changed, bool anim_changed) |
Recursively update this particular part and all of its descendents for the current frame. | |
virtual void | write_datagram (BamWriter *manager, Datagram &me) |
Function to write the important information in the particular object to a Datagram. | |
virtual int | complete_pointers (TypedWritable **p_list, BamReader *manager) |
Takes in a vector of pointes to TypedWritable objects that correspond to all the requests for pointers that this object made to BamReader. | |
int | get_type_index () const |
Returns the internal index number associated with this object's TypeHandle, a unique number for each different type. | |
bool | is_of_type (TypeHandle handle) const |
Returns true if the current object is or derives from the indicated type. | |
bool | is_exact_type (TypeHandle handle) const |
Returns true if the current object is the indicated type exactly. | |
int | get_ref_count () const |
Returns the current reference count. | |
int | ref () const |
Explicitly increments the reference count. | |
int | unref () const |
Explicitly decrements the reference count. | |
void | test_ref_count_integrity () const |
Does some easy checks to make sure that the reference count isn't completely bogus. | |
void | set_name (const string &name) |
void | clear_name () |
Resets the Namable's name to empty. | |
bool | has_name () const |
Returns true if the Namable has a nonempty name set, false if the name is empty. | |
const string & | get_name () const |
void | store_anim (AnimControl *control, const string &name) |
Associates the given AnimControl with this collection under the given name. | |
AnimControl * | find_anim (const string &name) const |
Returns the AnimControl associated with the given name, or NULL if no such control has been associated. | |
bool | unbind_anim (const string &name) |
Removes the AnimControl associated with the given name, if any. | |
int | get_num_anims () const |
Returns the number of AnimControls associated with this collection. | |
void | clear_anims () |
Disassociates all anims from this collection. | |
void | set_stop_event (const CPT_Event &stop_event) |
Sets the event that will be thrown when the next animation that is played eventually comes to a stop. | |
void | clear_stop_event () |
Indicates that the next-started animation will not throw a stop event when it comes to a stop. | |
bool | has_stop_event () const |
Returns true if a stop event has been established via set_stop_event(). | |
CPT_Event | get_stop_event () const |
Returns the event that has been established via set_stop_event(). | |
bool | play (const string &anim_name) |
Starts the named animation playing. | |
bool | play (const string &anim_name, int from, int to) |
Starts the named animation playing. | |
bool | loop (const string &anim_name, bool restart) |
Starts the named animation looping. | |
bool | loop (const string &anim_name, bool restart, int from, int to) |
Starts the named animation looping. | |
bool | stop (const string &anim_name) |
Stops the named animation. | |
bool | pose (const string &anim_name, int frame) |
Sets to a particular frame in the named animation. | |
void | play_all () |
Starts all animations playing. | |
void | play_all (int from, int to) |
Starts all animations playing. | |
void | loop_all (bool restart) |
Starts all animations looping. | |
void | loop_all (bool restart, int from, int to) |
Starts all animations looping. | |
bool | stop_all () |
Stops all currently playing animations. | |
void | pose_all (int frame) |
Sets all animations to the indicated frame. | |
int | get_frame (const string &anim_name) const |
Returns the current frame in the named animation, or 0 if the animation is not found. | |
int | get_frame () const |
Returns the current frame in the last-started animation. | |
int | get_num_frames (const string &anim_name) const |
Returns the total number of frames in the named animation, or 0 if the animation is not found. | |
bool | is_playing (const string &anim_name) const |
Returns true if the named animation is currently playing, false otherwise. | |
bool | is_playing () const |
Returns true if the last-started animation is currently playing, false otherwise. | |
string | which_anim_playing () const |
Returns the name of the bound AnimControl currently playing, if any. | |
Static Public Member Functions | |
void | register_with_read_factory (void) |
Factory method to generate a PartBundle object. | |
TypedWritable * | make_PartBundle (const FactoryParams ¶ms) |
Factory method to generate a PartBundle object. | |
TypeHandle | get_class_type () |
void | init_type () |
TypedWritable * | make_PartGroup (const FactoryParams ¶ms) |
Factory method to generate a PartGroup object. | |
Static Public Attributes | |
TypedWritable *const | Null = (TypedWritable*)0L |
Protected Types | |
typedef pvector< PointerTo< PartGroup > > | Children |
Protected Member Functions | |
PartBundle (const PartBundle ©) | |
Normally, you'd use make_copy() or copy_subgraph() to make a copy of this. | |
void | recompute_net_blend () |
Recomputes the total blending amount after a control effect has been adjusted. | |
void | clear_and_stop_except (AnimControl *control) |
Removes and stops all the currently activated AnimControls, except for the indicated one. | |
void | write_descendants (ostream &out, int indent_level) const |
Writes a brief description of all of the group's descendants. | |
void | write_descendants_with_value (ostream &out, int indent_level) const |
Writes a brief description of all of the group's descendants and their values. | |
virtual void | pick_channel_index (plist< int > &holes, int &next) const |
Walks the part hierarchy, looking for a suitable channel index number to use. | |
virtual void | bind_hierarchy (AnimGroup *anim, int channel_index) |
Binds the indicated anim hierarchy to the part hierarchy, at the given channel index number. | |
void | fillin (DatagramIterator &scan, BamReader *manager) |
Function that reads out of the datagram (or asks manager to read) all of the data that is needed to re-create this object and stores it in the appropiate place. | |
Protected Attributes | |
BlendType | _blend_type |
PartBundleNode * | _node |
AnimControl * | _last_control_set |
ChannelBlend | _blend |
float | _net_blend |
bool | _anim_changed |
Children | _children |
Static Private Attributes | |
TypeHandle | _type_handle |
Friends | |
class | PartBundleNode |
It defines the hierarchy of moving parts that make up an animatable object.
Definition at line 49 of file partBundle.h.
|
Definition at line 54 of file partBundle.h. |
|
Definition at line 103 of file partGroup.h. |
|
Definition at line 56 of file partBundle.h. |
|
Definition at line 57 of file partBundle.h. Referenced by control_begin(). |
|
Definition at line 72 of file partBundle.h. |
|
Definition at line 55 of file partGroup.h. |
|
Normally, you'd use make_copy() or copy_subgraph() to make a copy of this.
Definition at line 49 of file partBundle.cxx. References _anim_changed, and _net_blend. Referenced by PartBundle(). |
|
Normally, a PartBundle constructor should not be called directly--it will get created when a PartBundleNode is created.
Definition at line 73 of file partBundle.cxx. References PartBundle(). |
|
Calls advance_time() on all AnimControls currently in effect.
Definition at line 456 of file partBundle.cxx. |
|
Binds the animation to the bundle, if possible, and returns a new AnimControl that can be used to start and stop the animation. If the anim hierarchy does not match the part hierarchy, returns NULL. If hierarchy_match_flags is 0, only an exact match is accepted; otherwise, it may contain a union of PartGroup::HierarchyMatchFlags values indicating conditions that will be tolerated (but warnings will still be issued). This flavor of bind_anim() automatically stores the bound AnimControl in the PartBundle with the indicated name, so that it may later be referenced by name. This means that the animation will not be unbound until another animation with the same name is bound, or it is explicitly unbound with unbind_anim(). The return value is true if the animation was successfully bound, false if there was some error. Definition at line 434 of file partBundle.cxx. References PartGroup::do_update(), and NULL. |
|
Binds the animation to the bundle, if possible, and returns a new AnimControl that can be used to start and stop the animation. If the anim hierarchy does not match the part hierarchy, returns NULL. If hierarchy_match_flags is 0, only an exact match is accepted; otherwise, it may contain a union of PartGroup::HierarchyMatchFlags values indicating conditions that will be tolerated (but warnings will still be issued). This flavor of bind_anim() does not associate a name with the channel, and the AnimControl is not stored within the PartBundle; it is the user's responsibility to maintain the pointer. The animation will automatically unbind itself when the AnimControl destructs (i.e. its reference count goes to zero). Definition at line 355 of file partBundle.cxx. References _anim_changed, _blend, PartGroup::do_update(), AnimControl::mark_channels(), and NULL. Referenced by write(). |
|
Binds the indicated anim hierarchy to the part hierarchy, at the given channel index number.
Reimplemented in MovingPartBase. Definition at line 526 of file partGroup.cxx. Referenced by MovingPartBase::pick_channel_index(). |
|
Walks the part hierarchy in tandem with the indicated anim hierarchy, and returns true if the hierarchies match, false otherwise. If hierarchy_match_flags is 0, only an exact match is accepted; otherwise, it may contain a union of PartGroup::HierarchyMatchFlags values indicating conditions that will be tolerated (but warnings will still be issued). If there is a discrepancy, it is reported to the indicated output stream, if it is non-null. Definition at line 251 of file partGroup.cxx. |
|
Removes and stops all the currently activated AnimControls, except for the indicated one. This is a special internal function that's only called when _blend_type is BT_single, to automatically stop all the other currently-executing animations. Definition at line 640 of file partBundle.cxx. Referenced by make_copy(). |
|
Disassociates all anims from this collection.
Definition at line 151 of file animControlCollection.cxx. References AnimControlCollection::_controls. |
|
Sets the control effect of all AnimControls to zero (but does not "stop" the AnimControls). The character will no longer be affected by any animation, and will return to its original Jesus pose. The AnimControls which are no longer associated will not be using any CPU cycles, but they may still be in the "playing" state; if they are later reassociated with the PartBundle they will resume at their current frame as if they'd been running all along. Definition at line 182 of file partBundle.cxx. References _anim_changed, and _blend. |
|
Resets the Namable's name to empty.
Definition at line 82 of file namable.I. References Namable::_name, and INLINE. |
|
Indicates that the next-started animation will not throw a stop event when it comes to a stop. This does not affect any already-started animations. Definition at line 55 of file animControlCollection.I. References AnimControlCollection::_stop_event, INLINE, and NULL. |
|
Takes in a vector of pointes to TypedWritable objects that correspond to all the requests for pointers that this object made to BamReader.
Reimplemented from TypedWritable. Reimplemented in CharacterJoint. Definition at line 618 of file partGroup.cxx. Referenced by CharacterJoint::clear_local_transforms(). |
|
Called by the AnimControl whenever it starts an animation. This is just a hook so the bundle can do something, if necessary, before the animation starts. Definition at line 538 of file partBundle.cxx. Referenced by AnimControl::pingpong(), and AnimControl::play(). |
|
Returns an iterator that can be used to traverse the entire set of AnimControls currently in effect.
Definition at line 64 of file partBundle.I. References _blend, control_size_type, and INLINE. |
|
Returns an iterator that can be used to traverse the entire set of AnimControls currently in effect.
Definition at line 80 of file partBundle.I. |
|
Returns the number of entries between control_begin() and control_end(): the number of AnimControls currently in effect.
Definition at line 98 of file partBundle.I. Referenced by make_copy(). |
|
Allocates and returns a new copy of this node and of all of its children.
Definition at line 93 of file partGroup.cxx. References PartGroup::_children. |
|
Recursively update this particular part and all of its descendents for the current frame. This is not really public and is not intended to be called directly; it is called from the top of the tree by PartBundle::update(). The return value is true if any part has changed, false otherwise. Reimplemented in MovingPartBase. Definition at line 436 of file partGroup.cxx. References NULL. Referenced by bind_anim(). |
|
Function that reads out of the datagram (or asks manager to read) all of the data that is needed to re-create this object and stores it in the appropiate place.
Reimplemented from TypedWritable. Reimplemented in MovingPart< SwitchType >, CharacterJoint, MovingPart< ACScalarSwitchType >, and MovingPart< ACMatrixSwitchType >. Definition at line 594 of file partGroup.cxx. Referenced by CharacterJointBundle::make_copy(), and MovingPart< SwitchType >::output_value(). |
|
Method to ensure that any necessary clean up tasks that have to be performed by this object are performed.
Reimplemented from TypedWritable. Definition at line 583 of file partBundle.cxx. |
|
Returns the AnimControl associated with the given name, or NULL if no such control has been associated.
Definition at line 92 of file animControlCollection.cxx. Referenced by AnimControlCollection::get_frame(), AnimControlCollection::has_stop_event(), AnimControlCollection::loop(), and AnimControlCollection::play(). |
|
Returns the first descendant found with the indicated name, or NULL if no such descendant exists.
Definition at line 150 of file partGroup.cxx. References Namable::get_name(), PartGroupAlphabeticalOrder::operator()(), and PT. Referenced by PartGroup::get_num_children(). |
|
Reimplemented from PartGroup. Reimplemented in CharacterJointBundle. Definition at line 162 of file partBundle.h. |
|
Updates all the parts in the bundle to reflect the data for the current frame, whether we believe it needs it or not.
Definition at line 510 of file partBundle.cxx. |
|
Returns the entire mapping of AnimControls to blend effect.
Definition at line 114 of file partBundle.I. |
|
Returns the way the character responds to multiple animations being bound simultaneously.
Definition at line 34 of file partBundle.I. |
|
Returns the nth child of the group.
Definition at line 134 of file partGroup.cxx. References NULL. |
|
Reimplemented from PartGroup. Reimplemented in CharacterJointBundle. Definition at line 163 of file partBundle.h. |
|
Returns the amount by which the character is affected by the indicated AnimControl and its associated animation. See set_control_effect(). Definition at line 266 of file partBundle.cxx. References Namable::get_name(). |
|
Returns the current frame in the last-started animation.
Definition at line 247 of file animControlCollection.I. |
|
Returns the current frame in the named animation, or 0 if the animation is not found.
Definition at line 228 of file animControlCollection.I. References AnimControlCollection::find_anim(), AnimControl::get_num_frames(), INLINE, and NULL. |
|
|
Returns the PartBundleNode associated with this PartBundle.
Reimplemented in CharacterJointBundle. Definition at line 49 of file partBundle.I. References _blend. Referenced by CharacterJointBundle::CharacterJointBundle(). |
|
Returns the number of AnimControls associated with this collection.
Definition at line 138 of file animControlCollection.cxx. References AnimControlCollection::_controls. |
|
Returns the number of child nodes of the group.
Definition at line 120 of file partGroup.cxx. References PartGroup::_children, PartGroup::find_child(), Namable::get_name(), and NULL. |
|
Returns the total number of frames in the named animation, or 0 if the animation is not found.
Definition at line 302 of file animControlCollection.I. |
|
Returns the current reference count.
Definition at line 183 of file referenceCount.I. Referenced by RenderState::determine_bin_index(), RenderEffects::determine_show_bounds(), FontPool::ns_garbage_collect(), TexturePool::ns_garbage_collect(), MaterialPool::ns_get_material(), and TexturePool::ns_release_texture(). |
|
Returns the event that has been established via set_stop_event(). This is the event that will be thrown by animations that are started in the future when they stop. However, this may or may not be associated with any currently-playing animations. Definition at line 99 of file animControlCollection.I. |
|
Reimplemented from PartGroup. Reimplemented in CharacterJointBundle. Definition at line 159 of file partBundle.h. |
|
Returns the internal index number associated with this object's TypeHandle, a unique number for each different type. This is equivalent to get_type().get_index(). Definition at line 71 of file typedObject.I. References TypeHandle::get_name(), TypedObject::get_type(), and INLINE. |
|
Returns the TypeHandle associated with the ValueType we are concerned with. This is provided to allow a bit of run-time checking that joints and channels are matching properly in type. Reimplemented in MovingPart< SwitchType >, MovingPartBase, MovingPart< ACScalarSwitchType >, and MovingPart< ACMatrixSwitchType >. Definition at line 181 of file partGroup.cxx. |
|
Returns true if the Namable has a nonempty name set, false if the name is empty.
Definition at line 97 of file namable.I. References Namable::get_name(), and INLINE. Referenced by EggGroupUniquifier::EggGroupUniquifier(), Texture::read(), and Texture::Texture(). |
|
Returns true if a stop event has been established via set_stop_event(). If true, this means that animations that are to be started in the future will throw this event when they stop. However, it does not necessarily mean that the currently-playing animation will throw this event. Definition at line 78 of file animControlCollection.I. References AnimControlCollection::_last_started_control, AnimControlCollection::_stop_event, AnimControlCollection::find_anim(), INLINE, NULL, and AnimControl::play(). |
|
Reimplemented from PartGroup. Reimplemented in CharacterJointBundle. Definition at line 166 of file partBundle.h. Referenced by CharacterJointBundle::get_type(). |
|
Returns true if the current object is the indicated type exactly.
Definition at line 101 of file typedObject.I. Referenced by PT(), and CollisionNode::xform(). |
|
|
Returns true if the last-started animation is currently playing, false otherwise.
Definition at line 284 of file animControlCollection.I. |
|
Returns true if the named animation is currently playing, false otherwise.
Definition at line 265 of file animControlCollection.I. |
|
Starts the named animation looping.
Definition at line 169 of file animControlCollection.I. References AnimControlCollection::find_anim(), AnimControl::get_frame(), INLINE, and NULL. |
|
Starts the named animation looping.
Definition at line 150 of file animControlCollection.I. |
|
Starts all animations looping.
Definition at line 212 of file animControlCollection.cxx. References AnimControlCollection::_controls. |
|
Starts all animations looping.
Definition at line 196 of file animControlCollection.cxx. References AnimControlCollection::_controls. |
|
Allocates and returns a new copy of the node. Children are not copied, but see copy_subgraph(). Reimplemented from PartGroup. Reimplemented in CharacterJointBundle. Definition at line 92 of file partBundle.cxx. References _anim_changed, _blend_type, _last_control_set, BT_single, clear_and_stop_except(), control_size(), nassertv, and NULL. |
|
Factory method to generate a PartBundle object.
Definition at line 597 of file partBundle.cxx. |
|
Factory method to generate a PartGroup object.
Definition at line 646 of file partGroup.cxx. |
|
Writes a one-line description of the bundle.
Reimplemented from Namable. Definition at line 289 of file partBundle.cxx. |
|
Walks the part hierarchy, looking for a suitable channel index number to use. Available index numbers are the elements of the holes set, as well as next to infinity. Reimplemented in MovingPartBase. Definition at line 507 of file partGroup.cxx. References PartGroup::_children, PartGroup::_num_children, DCAST, TypeHandle::get_name(), PartGroup::get_type(), and TypedWritable::Null. |
|
Starts the named animation playing.
Definition at line 131 of file animControlCollection.I. |
|
Starts the named animation playing.
Definition at line 112 of file animControlCollection.I. References AnimControlCollection::_last_started_control, AnimControlCollection::find_anim(), AnimControl::loop(), and NULL. |
|
Starts all animations playing.
Definition at line 180 of file animControlCollection.cxx. References AnimControlCollection::_controls. |
|
Starts all animations playing.
Definition at line 164 of file animControlCollection.cxx. References AnimControlCollection::_controls. |
|
Sets to a particular frame in the named animation.
Definition at line 207 of file animControlCollection.I. References NULL. |
|
Sets all animations to the indicated frame.
Definition at line 254 of file animControlCollection.cxx. |
|
Recomputes the total blending amount after a control effect has been adjusted. This value must be kept up-to-date so we can normalize the blending amounts. Definition at line 563 of file partBundle.cxx. |
|
Explicitly increments the reference count. User code should avoid using ref() and unref() directly, which can result in missed reference counts. Instead, let a PointerTo object manage the reference counting automatically. This function is const, even though it changes the object, because generally fiddling with an object's reference count isn't considered part of fiddling with the object. An object might be const in other ways, but we still need to accurately count the number of references to it. The return value is the new reference count. Definition at line 225 of file referenceCount.I. Referenced by ClientDevice::ClientDevice(), EggGroupNode::find_textures(), EggGroupNode::r_apply_texmats(), EggGroupNode::r_flatten_transforms(), and EggGroupNode::reverse_vertex_ordering(). |
|
Factory method to generate a PartBundle object.
Reimplemented from PartGroup. Reimplemented in CharacterJointBundle. Definition at line 618 of file partBundle.cxx. |
|
Defines the way the character responds to multiple set_control_effect()). By default, the blend_type is BT_single, which disallows multiple animations. In BT_single mode, it is not necessary to explicitly set the control_effect when starting an animation; starting the animation will implicitly remove the control_effect from the previous animation and set it on the current one. However, if the blend_type is set to any other value, the control_effect must be explicitly set via set_control_effect() whenever an animation is to affect the character. See partBundle.h for a description of the meaning of each of the BlendType values. Definition at line 136 of file partBundle.cxx. References _anim_changed, _blend, and _net_blend. |
|
Sets the amount by which the character is affected by the indicated AnimControl (and its associated animation). Normally, this will only be zero or one. Zero indicates the animation does not affect the character, and one means it does. If the blend_type is not BT_single (see set_blend_type()), it is possible to have multiple AnimControls in effect simultaneously. In this case, the effect is a weight that indicates the relative importance of each AnimControl to the final animation. Definition at line 222 of file partBundle.cxx. |
|
Definition at line 69 of file namable.I. References Namable::_name. Referenced by BuilderBucket::BuilderBucket(), SceneGraphReducer::do_flatten_siblings(), Texture::read(), PandaNode::reparent(), and Texture::Texture(). |
|
Sets the event that will be thrown when the next animation that is played eventually comes to a stop. Setting this does not affect any stop event that is pending from a previously-started animation. Definition at line 38 of file animControlCollection.I. References AnimControlCollection::_stop_event, INLINE, and NULL. |
|
Sorts the children nodes at each level of the hierarchy into alphabetical order. This should be done after creating the hierarchy, to guarantee that the correct names will match up together when the AnimBundle is later bound to a PlayerRoot. Definition at line 211 of file partGroup.cxx. References AnimGroup::get_num_children(). |
|
Stops the named animation.
Definition at line 188 of file animControlCollection.I. References AnimControlCollection::_last_started_control, AnimControl::get_frame(), INLINE, and NULL. |
|
Stops all currently playing animations. Returns true if any animations were stopped, false if none were playing. Definition at line 232 of file animControlCollection.cxx. |
|
Associates the given AnimControl with this collection under the given name. The AnimControl will remain associated until a new AnimControl is associated with the same name later, or until unbind_anim() is called with this name. Definition at line 69 of file animControlCollection.cxx. References AnimControlCollection::_controls, and NULL. Referenced by write(). |
|
Does some easy checks to make sure that the reference count isn't completely bogus.
Definition at line 328 of file referenceCount.I. References INLINE. Referenced by EggNode::determine_bin(), and ReferenceCount::~ReferenceCount(). |
|
Removes the AnimControl associated with the given name, if any. Returns true if an AnimControl was removed, false if there was no AnimControl with the indicated name. Definition at line 115 of file animControlCollection.cxx. References AnimControlCollection::_controls. |
|
Explicitly decrements the reference count. Note that the object will not be implicitly deleted by unref() simply because the reference count drops to zero. (Having a member function delete itself is problematic; plus, we don't have a virtual destructor anyway.) However, see the helper function unref_delete(). User code should avoid using ref() and unref() directly, which can result in missed reference counts. Instead, let a PointerTo object manage the reference counting automatically. This function is const, even though it changes the object, because generally fiddling with an object's reference count isn't considered part of fiddling with the object. An object might be const in other ways, but we still need to accurately count the number of references to it. The return value is the new reference count. Definition at line 293 of file referenceCount.I. References INLINE. Referenced by RenderState::determine_bin_index(), and RenderEffects::determine_show_bounds(). |
|
Updates all the parts in the bundle to reflect the data for the current frame (as set in each of the AnimControls). Returns true if any part has changed as a result of this, or false otherwise. Definition at line 483 of file partBundle.cxx. References _blend. |
|
Returns the name of the bound AnimControl currently playing, if any. If more than one AnimControl is currently playing, returns all of the names separated by spaces. Definition at line 276 of file animControlCollection.cxx. |
|
Writes a brief description of the bundle and all of its descendants.
Reimplemented from PartGroup. Definition at line 304 of file partBundle.cxx. References bind_anim(), NULL, PT, and AnimControlCollection::store_anim(). |
|
Function to write the important information in the particular object to a Datagram.
Implements TypedWritableReferenceCount. Reimplemented in MovingPart< SwitchType >, CharacterJoint, MovingPart< ACScalarSwitchType >, and MovingPart< ACMatrixSwitchType >. Definition at line 568 of file partGroup.cxx. Referenced by MovingPart< SwitchType >::make_initial_channel(). |
|
Writes a brief description of all of the group's descendants.
Definition at line 462 of file partGroup.cxx. Referenced by MovingPartBase::MovingPartBase(). |
|
Writes a brief description of all of the group's descendants and their values.
Definition at line 481 of file partGroup.cxx. Referenced by MovingPartBase::write(). |
|
Writes a brief description of the group, showing its current value, and that of all of its descendants.
Reimplemented in MovingPartBase. Definition at line 405 of file partGroup.cxx. |
|
Definition at line 175 of file partBundle.h. |
|
Definition at line 149 of file partBundle.h. Referenced by bind_anim(), clear_control_effects(), make_copy(), PartBundle(), and set_blend_type(). |
|
Definition at line 147 of file partBundle.h. Referenced by bind_anim(), clear_control_effects(), control_begin(), control_end(), get_node(), set_blend_type(), and update(). |
|
Definition at line 143 of file partBundle.h. Referenced by make_copy(). |
|
Definition at line 104 of file partGroup.h. Referenced by PartGroup::copy_subgraph(), PartGroup::get_num_children(), MovingPartBase::MovingPartBase(), PartGroup::pick_channel_index(), Character::update_to_now(), PartGroup::write(), and MovingPartBase::write(). |
|
Definition at line 146 of file partBundle.h. Referenced by make_copy(). |
|
Definition at line 148 of file partBundle.h. Referenced by PartBundle(), and set_blend_type(). |
|
Definition at line 144 of file partBundle.h. Referenced by get_blend_type(). |
|
Reimplemented from PartGroup. Reimplemented in CharacterJointBundle. Definition at line 34 of file partBundle.cxx. |
|
Definition at line 25 of file typedWritable.cxx. Referenced by Child::complete_pointers(), Parent::complete_pointers(), Person::complete_pointers(), LoaderFileTypeBam::get_extension(), PartGroup::pick_channel_index(), BamReader::read_pointer(), and AnimGroup::write_datagram(). |