|
Developer Documentation
|
Public Types | |
| typedef PointT | Point |
| typedef Point::value_type | Scalar |
| typedef PoseT< PointT > | Pose |
| typedef InterpolationMatrixManipulatorT< Scalar > | MatrixManipulator |
| typedef InterpolationT< Scalar > | Interpolator |
| typedef std::vector< Scalar > | TargetType |
Public Types inherited from AnimationT< PointT > | |
| typedef PointT | Point |
| typedef Point::value_type | Scalar |
| typedef PoseT< PointT > | Pose |
Public Member Functions | |
| InterpolationAnimationT (const InterpolationAnimationT< PointT > &_other) | |
| Copy constructor. | |
| InterpolationAnimationT (Skeleton *_skeleton, MatrixManipulator *_matrixManipulator) | |
| Creates a new empty animation. | |
| virtual AnimationT< PointT > * | copy () |
| virtual void | updateFromGlobal (unsigned int _index) |
| Updates the local matrix using the global matrix. | |
| virtual bool | getMinInput (Scalar &_result) |
| virtual bool | getMaxInput (Scalar &_result) |
| Pose * | getReference () |
| virtual void | clearPoseCache () |
Frame access | |
There is one pose per frame. | |
| virtual Pose * | pose (unsigned int _iFrame) |
| Returns a pointer to the pose calculated for the given frame. | |
| virtual Pose * | pose (unsigned int _iFrame, Pose *_reference) |
| Returns a pointer to the pose calculated for the given frame. | |
| unsigned int | frameCount () |
| Returns the number of frames stored in this pose. | |
Synchronization | |
Use these methods to keep the poses in sync with the number (and indices) of the joints. | |
| virtual void | insertJointAt (unsigned int _index) |
| Called by the skeleton as a new joint is inserted. | |
| virtual void | removeJointAt (unsigned int _index) |
| Called by the skeleton as a joint is deleted. | |
Interpolators access | |
We use only interpolators with time as input. | |
| void | addInterpolator (InterpolationT< double > *_interpolator) |
| Add an interpolator. | |
| Interpolator * | interpolator (unsigned int _index) |
| Get the i-th interpolator. | |
| unsigned int | interpolatorCount () |
| Get the number of interpolators. | |
InfluencedJoints access | |
| void | addInfluencedJoint (int _joint) |
| bool | isInfluenced (int _joint) |
| std::vector< int > & | influencedJoints () |
MatrixManipulator access | |
| MatrixManipulator * | matrixManipulator () |
| Get the matrix manipulator. | |
Public Member Functions inherited from AnimationT< PointT > | |
| AnimationT (std::string _name="") | |
| std::string | name () |
| void | setName (std::string _name) |
| int | fps () |
| void | setFps (int _fps) |
Static Public Attributes | |
| static const int | FPS = 60 |
Protected Member Functions | |
| unsigned int | calcAbsoluteMaxForInterpolator (uint _index) |
| Calculates the last frame that interpolator _index is responsible for. | |
Protected Attributes | |
| Skeleton * | skeleton_ |
| std::vector< int > | influencedJoints_ |
| std::vector< Interpolator * > | interpolators_ |
| std::map< Interpolator *, std::vector< TargetType > > | precalculations_ |
| MatrixManipulator * | matrixManipulator_ |
| unsigned int | frames_ |
| std::map< unsigned int, Pose * > | interpolatedPoses_ |
Protected Attributes inherited from AnimationT< PointT > | |
| std::string | name_ |
| int | fps_ |
Friends | |
| template<typename > | |
| class | SkeletonT |
Definition at line 52 of file InterpolationAnimationT.hh.
| typedef InterpolationT<Scalar> InterpolationAnimationT< PointT >::Interpolator |
Definition at line 62 of file InterpolationAnimationT.hh.
| typedef InterpolationMatrixManipulatorT<Scalar> InterpolationAnimationT< PointT >::MatrixManipulator |
Definition at line 61 of file InterpolationAnimationT.hh.
| typedef PointT InterpolationAnimationT< PointT >::Point |
Definition at line 58 of file InterpolationAnimationT.hh.
| typedef PoseT<PointT> InterpolationAnimationT< PointT >::Pose |
Definition at line 60 of file InterpolationAnimationT.hh.
| typedef Point::value_type InterpolationAnimationT< PointT >::Scalar |
Definition at line 59 of file InterpolationAnimationT.hh.
| typedef std::vector<Scalar> InterpolationAnimationT< PointT >::TargetType |
Definition at line 63 of file InterpolationAnimationT.hh.
| InterpolationAnimationT< PointT >::InterpolationAnimationT | ( | const InterpolationAnimationT< PointT > & | _other | ) |
Copy constructor.
This animation will copy all frames from the given animation. After the call returns they are completely independent.
| _other | The animation to copy from |
Definition at line 62 of file InterpolationAnimationT_impl.hh.
| InterpolationAnimationT< PointT >::InterpolationAnimationT | ( | Skeleton * | _skeleton, |
| MatrixManipulator * | _matrixManipulator | ||
| ) |
Creates a new empty animation.
| _skeleton | The skeleton that will hold this animation |
| _matrixManipulator | Interpolator that translates the interpolation into matrix values |
Definition at line 80 of file InterpolationAnimationT_impl.hh.
|
virtual |
Definition at line 91 of file InterpolationAnimationT_impl.hh.
|
inline |
Definition at line 188 of file InterpolationAnimationT.hh.
| void InterpolationAnimationT< PointT >::addInterpolator | ( | InterpolationT< double > * | _interpolator | ) |
Add an interpolator.
| _interpolator | New interpolator |
Definition at line 216 of file InterpolationAnimationT_impl.hh.
|
protected |
Calculates the last frame that interpolator _index is responsible for.
Definition at line 269 of file InterpolationAnimationT_impl.hh.
|
inlinevirtual |
Reimplemented from AnimationT< PointT >.
Definition at line 215 of file InterpolationAnimationT.hh.
|
virtual |
Implements AnimationT< PointT >.
Definition at line 99 of file InterpolationAnimationT_impl.hh.
|
inlinevirtual |
Returns the number of frames stored in this pose.
Implements AnimationT< PointT >.
Reimplemented in MultiInterpolationAnimationT< PointT >.
Definition at line 175 of file InterpolationAnimationT_impl.hh.
|
virtual |
Definition at line 299 of file InterpolationAnimationT_impl.hh.
|
virtual |
Definition at line 282 of file InterpolationAnimationT_impl.hh.
|
inline |
Definition at line 213 of file InterpolationAnimationT.hh.
| std::vector< int > & InterpolationAnimationT< PointT >::influencedJoints | ( | ) |
Definition at line 327 of file InterpolationAnimationT_impl.hh.
|
virtual |
Called by the skeleton as a new joint is inserted.
The call is dispatched to all poses stored in the animation. See BaseNode::insert_at for more information.
| _index | The new joint is inserted at this position. Insert new joints at the end by passing SkeletonT<>::jointCount as parameter. |
Implements AnimationT< PointT >.
Reimplemented in MultiInterpolationAnimationT< PointT >.
Definition at line 183 of file InterpolationAnimationT_impl.hh.
| InterpolationT< typename PointT::value_type > * InterpolationAnimationT< PointT >::interpolator | ( | unsigned int | _index | ) |
Get the i-th interpolator.
| _index | Number of the interpolator |
Definition at line 247 of file InterpolationAnimationT_impl.hh.
| unsigned int InterpolationAnimationT< PointT >::interpolatorCount | ( | ) |
Get the number of interpolators.
Definition at line 258 of file InterpolationAnimationT_impl.hh.
| bool InterpolationAnimationT< PointT >::isInfluenced | ( | int | _joint | ) |
Definition at line 316 of file InterpolationAnimationT_impl.hh.
|
inline |
Get the matrix manipulator.
Definition at line 209 of file InterpolationAnimationT.hh.
|
virtual |
Returns a pointer to the pose calculated for the given frame.
| _iFrame | The frame number for which the pose should be calculated. This is always from 0..frames even if the animation starts with an input value other than 0. |
Implements AnimationT< PointT >.
Reimplemented in MultiInterpolationAnimationT< PointT >.
Definition at line 106 of file InterpolationAnimationT_impl.hh.
|
virtual |
Returns a pointer to the pose calculated for the given frame.
| _iFrame | The frame number for which the pose should be calculated. This is always from 0..frames even if the animation starts with an input value other than 0. |
| _reference | Reference pose |
Reimplemented in MultiInterpolationAnimationT< PointT >.
Definition at line 114 of file InterpolationAnimationT_impl.hh.
|
virtual |
Called by the skeleton as a joint is deleted.
The call is dispatched to all poses stored in this animation. See BasePoseT<>::remove_at for more information.
| _index | The index of the joint that is being deleted. |
Implements AnimationT< PointT >.
Reimplemented in MultiInterpolationAnimationT< PointT >.
Definition at line 192 of file InterpolationAnimationT_impl.hh.
|
virtual |
Updates the local matrix using the global matrix.
Called when a joints parent is changed. Note: Does nothing at the moment
| _index | The joints index |
Implements AnimationT< PointT >.
Reimplemented in MultiInterpolationAnimationT< PointT >.
Definition at line 208 of file InterpolationAnimationT_impl.hh.
Definition at line 55 of file InterpolationAnimationT.hh.
|
static |
Definition at line 94 of file InterpolationAnimationT.hh.
|
protected |
Definition at line 87 of file InterpolationAnimationT.hh.
|
protected |
Definition at line 81 of file InterpolationAnimationT.hh.
|
protected |
Definition at line 89 of file InterpolationAnimationT.hh.
|
protected |
Definition at line 82 of file InterpolationAnimationT.hh.
|
protected |
Definition at line 86 of file InterpolationAnimationT.hh.
|
protected |
Definition at line 85 of file InterpolationAnimationT.hh.
|
protected |
Definition at line 79 of file InterpolationAnimationT.hh.