Panda3D
|
This is a particular kind of MovingPart that accepts a matrix each frame. More...
#include "movingPartMatrix.h"
Public Member Functions | |
MovingPartMatrix (PartGroup *parent, const string &name, const LMatrix4 &default_value) | |
virtual bool | apply_control (PandaNode *node) |
Specifies a node to influence this particular joint so that it will always hold the node's transform. | |
virtual bool | apply_freeze_matrix (const LVecBase3 &pos, const LVecBase3 &hpr, const LVecBase3 &scale) |
Freezes this particular joint so that it will always hold the specified transform. | |
virtual TypeHandle | force_init_type () |
virtual void | get_blend_value (const PartBundle *root) |
Attempts to blend the various matrix values indicated, and sets the _value member to the resulting matrix. | |
virtual TypeHandle | get_type () const |
virtual AnimChannelBase * | make_default_channel () const |
Creates and returns a new AnimChannel that is not part of any hierarchy, but that returns the default value associated with this part. | |
Static Public Member Functions | |
static TypeHandle | get_class_type () |
static void | init_type () |
static TypedWritable * | make_MovingPartMatrix (const FactoryParams ¶ms) |
Factory method to generate a MovingPartMatrix object. | |
static void | register_with_read_factory () |
Factory method to generate a MovingPartMatrix object. | |
Protected Member Functions | |
MovingPartMatrix (const MovingPartMatrix ©) | |
Normally, you'd use make_copy() or copy_subgraph() to make a copy of this. |
This is a particular kind of MovingPart that accepts a matrix each frame.
Definition at line 32 of file movingPartMatrix.h.
MovingPartMatrix::MovingPartMatrix | ( | const MovingPartMatrix & | copy | ) | [inline, protected] |
Normally, you'd use make_copy() or copy_subgraph() to make a copy of this.
Definition at line 23 of file movingPartMatrix.I.
bool MovingPartMatrix::apply_control | ( | PandaNode * | node | ) | [virtual] |
Specifies a node to influence this particular joint so that it will always hold the node's transform.
Returns true if this is a joint that can be so controlled, false otherwise. This is called internally by PartBundle::control_joint().
Reimplemented from PartGroup.
Definition at line 402 of file movingPartMatrix.cxx.
References AnimChannelMatrixDynamic::set_value_node().
bool MovingPartMatrix::apply_freeze_matrix | ( | const LVecBase3 & | pos, |
const LVecBase3 & | hpr, | ||
const LVecBase3 & | scale | ||
) | [virtual] |
Freezes this particular joint so that it will always hold the specified transform.
Returns true if this is a joint that can be so frozen, false otherwise. This is called internally by PartBundle::freeze_joint().
Reimplemented from PartGroup.
Definition at line 387 of file movingPartMatrix.cxx.
void MovingPartMatrix::get_blend_value | ( | const PartBundle * | root | ) | [virtual] |
Attempts to blend the various matrix values indicated, and sets the _value member to the resulting matrix.
Implements MovingPartBase.
Definition at line 64 of file movingPartMatrix.cxx.
References AnimControl::get_channel_index(), AnimInterface::get_frac(), AnimInterface::get_frame(), AnimChannel< SwitchType >::get_hpr(), AnimInterface::get_next_frame(), AnimChannel< SwitchType >::get_pos(), AnimChannel< SwitchType >::get_quat(), AnimChannel< SwitchType >::get_scale(), AnimChannel< SwitchType >::get_shear(), AnimChannel< SwitchType >::get_value_no_scale_shear(), LMatrix4f::scale_shear_mat(), LMatrix4f::set_row(), and LMatrix4f::zeros_mat().
AnimChannelBase * MovingPartMatrix::make_default_channel | ( | ) | const [virtual] |
Creates and returns a new AnimChannel that is not part of any hierarchy, but that returns the default value associated with this part.
Reimplemented from MovingPart< ACMatrixSwitchType >.
Definition at line 50 of file movingPartMatrix.cxx.
TypedWritable * MovingPartMatrix::make_MovingPartMatrix | ( | const FactoryParams & | params | ) | [static] |
Factory method to generate a MovingPartMatrix object.
Definition at line 415 of file movingPartMatrix.cxx.
References MovingPart< SwitchType >::fillin().
Referenced by register_with_read_factory().
void MovingPartMatrix::register_with_read_factory | ( | ) | [static] |
Factory method to generate a MovingPartMatrix object.
Reimplemented from PartGroup.
Reimplemented in CharacterJoint.
Definition at line 431 of file movingPartMatrix.cxx.
References BamReader::get_factory(), make_MovingPartMatrix(), and Factory< Type >::register_factory().