Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

EggJointNodePointer Class Reference

This stores a pointer back to a node. More...

#include <eggJointNodePointer.h>

Inheritance diagram for EggJointNodePointer:

EggJointPointer EggBackPointer TypedObject List of all members.

Public Member Functions

 EggJointNodePointer (EggObject *object)
virtual int get_num_frames () const
 Returns the number of frames of animation for this particular joint.

virtual LMatrix4d get_frame (int n) const
 Returns the transform matrix corresponding to this joint position in the nth frame.

virtual void set_frame (int n, const LMatrix4d &mat)
 Sets the transform matrix corresponding to this joint position in the nth frame.

virtual bool add_rebuild_frame (const LMatrix4d &mat)
 Adds a new frame to the set of rebuild frames.

virtual bool do_rebuild ()
 Rebuilds the entire table all at once, based on the frames added by repeated calls to add_rebuild_frame() since the last call to begin_rebuild().

virtual TypeHandle get_type () const
virtual TypeHandle force_init_type ()
virtual bool add_frame (const LMatrix4d &mat)
 Appends a new frame onto the end of the data, if possible; returns true if not possible, or false otherwise (e.g.

void begin_rebuild ()
 Resets the set of rebuild frames in preparation for rebuilding the complete table of frames.

virtual void optimize ()
 Resets the table before writing to disk so that redundant rows (e.g.

int get_type_index () const
bool is_of_type (TypeHandle handle) const
bool is_exact_type (TypeHandle handle) const

Static Public Member Functions

TypeHandle get_class_type ()
void init_type ()

Protected Types

typedef pvector< LMatrix4d > RebuildFrames

Protected Attributes

RebuildFrames _rebuild_frames

Private Attributes

PointerTo< EggGroup_joint

Static Private Attributes

TypeHandle _type_handle

Detailed Description

This stores a pointer back to a node.

Definition at line 39 of file eggJointNodePointer.h.


Member Typedef Documentation

typedef pvector<LMatrix4d> EggJointPointer::RebuildFrames [protected, inherited]
 

Definition at line 62 of file eggJointPointer.h.


Constructor & Destructor Documentation

EggJointNodePointer::EggJointNodePointer EggObject object  ) 
 

Definition at line 40 of file eggJointNodePointer.cxx.

References _joint.


Member Function Documentation

bool EggJointPointer::add_frame const LMatrix4d &  mat  )  [virtual, inherited]
 

Appends a new frame onto the end of the data, if possible; returns true if not possible, or false otherwise (e.g.

for a static joint).

Reimplemented in EggMatrixTablePointer.

Definition at line 41 of file eggJointPointer.cxx.

References EggJointPointer::_rebuild_frames.

bool EggJointNodePointer::add_rebuild_frame const LMatrix4d &  mat  )  [virtual]
 

Adds a new frame to the set of rebuild frames.

See begin_rebuild() and do_rebuild(). Returns true if this is valid, false otherwise (e.g. adding multiple frames to a static joint).

Reimplemented from EggJointPointer.

Definition at line 144 of file eggJointNodePointer.cxx.

void EggJointPointer::begin_rebuild  )  [inherited]
 

Resets the set of rebuild frames in preparation for rebuilding the complete table of frames.

Repeated calls to add_rebuild_frame() will build up the frames without changing the values returned by get_frame(); the table will eventually be updated when do_rebuild is called.

Definition at line 64 of file eggJointPointer.cxx.

bool EggJointNodePointer::do_rebuild  )  [virtual]
 

Rebuilds the entire table all at once, based on the frames added by repeated calls to add_rebuild_frame() since the last call to begin_rebuild().

Until do_rebuild() is called, the animation table is not changed.

The return value is true if all frames are acceptable, or false if there is some problem.

Reimplemented from EggJointPointer.

Definition at line 177 of file eggJointNodePointer.cxx.

virtual TypeHandle EggJointNodePointer::force_init_type void   )  [inline, virtual]
 

Reimplemented from EggJointPointer.

Definition at line 65 of file eggJointNodePointer.h.

TypeHandle EggJointNodePointer::get_class_type void   )  [inline, static]
 

Reimplemented from EggJointPointer.

Definition at line 54 of file eggJointNodePointer.h.

LMatrix4d EggJointNodePointer::get_frame int  n  )  const [virtual]
 

Returns the transform matrix corresponding to this joint position in the nth frame.

In the case of a EggJointNodePointer, which just stores a pointer to a entry for a character model (not an animation table), there is always exactly one frame: the rest pose.

Implements EggJointPointer.

Definition at line 98 of file eggJointNodePointer.cxx.

References EggJointPointer::_rebuild_frames, and EggJointPointer::add_rebuild_frame().

int EggJointNodePointer::get_num_frames  )  const [virtual]
 

Returns the number of frames of animation for this particular joint.

In the case of a EggJointNodePointer, which just stores a pointer to a entry for a character model (not an animation table), there is always exactly one frame: the rest pose.

Implements EggJointPointer.

Definition at line 73 of file eggJointNodePointer.cxx.

References _joint, and nassertr.

virtual TypeHandle EggJointNodePointer::get_type void   )  const [inline, virtual]
 

Reimplemented from EggJointPointer.

Definition at line 62 of file eggJointNodePointer.h.

References _type_handle.

void EggJointNodePointer::init_type void   )  [inline, static]
 

Reimplemented from EggJointPointer.

Definition at line 57 of file eggJointNodePointer.h.

Referenced by ConfigureFn().

void EggJointPointer::optimize  )  [virtual, inherited]
 

Resets the table before writing to disk so that redundant rows (e.g.

i { 1 1 1 1 1 1 1 1 }) are collapsed out.

Reimplemented in EggMatrixTablePointer.

Definition at line 134 of file eggJointPointer.cxx.

Referenced by EggJointData::do_rebuild().

void EggJointNodePointer::set_frame int  n,
const LMatrix4d &  mat
[virtual]
 

Sets the transform matrix corresponding to this joint position in the nth frame.

In the case of a EggJointNodePointer, which just stores a pointer to a entry for a character model (not an animation table), there is always exactly one frame: the rest pose.

Implements EggJointPointer.

Definition at line 124 of file eggJointNodePointer.cxx.

References _joint, and EggJointPointer::_rebuild_frames.


Member Data Documentation

PointerTo< EggGroup > EggJointNodePointer::_joint [private]
 

Definition at line 51 of file eggJointNodePointer.h.

Referenced by EggJointNodePointer(), get_num_frames(), and set_frame().

RebuildFrames EggJointPointer::_rebuild_frames [protected, inherited]
 

Definition at line 63 of file eggJointPointer.h.

Referenced by EggMatrixTablePointer::add_frame(), EggJointPointer::add_frame(), get_frame(), and set_frame().

TypeHandle EggJointNodePointer::_type_handle [static, private]
 

Reimplemented from EggJointPointer.

Definition at line 30 of file eggJointNodePointer.cxx.

Referenced by get_type().


The documentation for this class was generated from the following files:
Generated on Fri May 2 03:26:15 2003 for Panda-Tool by doxygen1.3