|
V-ART
|
Controllers for joint movement. More...
#include <jointmover.h>
Public Member Functions | |
| JointMover () | |
| JointMover (Joint *newJointPtr, float newDuration, const Interpolator &interpolator) | |
| ~JointMover () | |
| void | Move () |
| Moves the associated joint. More... | |
| void | AttachToJoint (Joint *newJointPtr) |
| Sets the associated joint. More... | |
| const VART::Joint * | GetAttachedJoint () const |
| Returns the associated joint. More... | |
| void | AddDofMover (Joint::DofID dof, float iniTime, float finTime, float finPos) |
| Creates a DofMover. More... | |
| NoisyDofMover * | AddNoisyDofMover (Joint::DofID dof, float iniTime, float finTime, float finPos) |
| Creates a noisy DofMover. More... | |
| DofMover * | GetDofMover (Joint::DofID dof) |
| Return the DofMover working on given Dof. More... | |
| void | SetDuration (float newDuration) |
| Sets the total movement duration (in seconds). More... | |
| float | GetDuration () |
| Return the total movement duration (in seconds). More... | |
| void | SetInterpolator (const Interpolator &interp) |
| Changes the associated interpolator. More... | |
| const Interpolator * | GetInterpolator () |
| Returns a pointer to the associated interpolator. NULL is returned if there are no interpolator associated. More... | |
| void | DeactivateDofMovers () |
| Deactivates all DOF movers. More... | |
| void | MultiplyTimes (float value) |
| Changes starting/ending times of all dof movers. More... | |
| void | GetFinalTimes (std::list< float > *resultPtr) |
| Returns a list with all different final times for every dof mover. More... | |
| void | CopyFrom (VART::JointMover &jointMover, VART::Joint *targetJoint) |
| Copy jointMover data to this jointMover, setting its jointPtr atribute to the targetJoint. More... | |
| void | ModifyDofMovers (DMModifier &modifier) |
| Modifies noisy dof movers. More... | |
Static Public Attributes | |
| static float | goalTime |
Protected Attributes | |
| Joint * | jointPtr |
| Associated joint. More... | |
| float | duration |
| float | minimumDuration |
| const Interpolator * | interpolatorPtr |
| std::list< DofMover * > | dofMoverList |
Friends | |
| std::ostream & | operator<< (std::ostream &output, const JointMover &mover) |
Controllers for joint movement.
Joint movers contain a set of DOF movers (see DofMover). They control how a joint moves in a particular action (see Action).
Definition at line 22 of file jointmover.h.
| VART::JointMover::JointMover | ( | ) |
Definition at line 20 of file jointmover.cpp.
| VART::JointMover::JointMover | ( | VART::Joint * | newJointPtr, |
| float | newDuration, | ||
| const Interpolator & | interpolator | ||
| ) |
Definition at line 26 of file jointmover.cpp.
| VART::JointMover::~JointMover | ( | ) |
Definition at line 35 of file jointmover.cpp.
| void VART::JointMover::AddDofMover | ( | Joint::DofID | dof, |
| float | iniTime, | ||
| float | finTime, | ||
| float | finPos | ||
| ) |
Creates a DofMover.
| dof | [in] DOF ID on which the new DOF mover will act |
| iniTime | [in] Initial movement time (in range [0..1]) |
| finTime | [in] Final movement time (in range [0..1]) |
| finPos | [in] Final movement position (in range [0..1]) |
Definition at line 59 of file jointmover.cpp.
References VART::DofMover::Initialize(), VART::DofMover::SetDof(), and VART::DofMover::targetDofPtr.
Referenced by VART::XmlJointAction::ParseDofMovement(), and VART::XmlAction::ParseDofMovement().
| VART::NoisyDofMover * VART::JointMover::AddNoisyDofMover | ( | Joint::DofID | dof, |
| float | iniTime, | ||
| float | finTime, | ||
| float | finPos | ||
| ) |
Creates a noisy DofMover.
| dof | [in] DOF ID on which the new DOF mover will act |
| iniTime | [in] Initial movement time (in range [0..1]) |
| finTime | [in] Final movement time (in range [0..1]) |
| finPos | [in] Final movement position (in range [0..1]) |
Definition at line 72 of file jointmover.cpp.
References VART::NoisyDofMover::Initialize(), VART::DofMover::SetDof(), and VART::DofMover::targetDofPtr.
Referenced by VART::XmlJointAction::ParseDofMovement(), and VART::XmlAction::ParseDofMovement().
|
inline |
| void VART::JointMover::CopyFrom | ( | VART::JointMover & | jointMover, |
| VART::Joint * | targetJoint | ||
| ) |
Copy jointMover data to this jointMover, setting its jointPtr atribute to the targetJoint.
Definition at line 130 of file jointmover.cpp.
References dofMoverList, duration, VART::DofMover::finalTime, VART::Joint::GetDofID(), VART::DofMover::initialTime, interpolatorPtr, jointPtr, minimumDuration, and VART::DofMover::targetPosition.
Referenced by VART::Action::AddJointMover().
| void VART::JointMover::DeactivateDofMovers | ( | ) |
Deactivates all DOF movers.
Definition at line 87 of file jointmover.cpp.
|
inline |
| VART::DofMover * VART::JointMover::GetDofMover | ( | Joint::DofID | dof | ) |
Return the DofMover working on given Dof.
Definition at line 107 of file jointmover.cpp.
|
inline |
Return the total movement duration (in seconds).
Definition at line 61 of file jointmover.h.
References duration.
Referenced by VART::Action::AddJointMover().
| void VART::JointMover::GetFinalTimes | ( | std::list< float > * | resultPtr | ) |
Returns a list with all different final times for every dof mover.
Definition at line 122 of file jointmover.cpp.
|
inline |
Returns a pointer to the associated interpolator. NULL is returned if there are no interpolator associated.
Definition at line 68 of file jointmover.h.
References interpolatorPtr.
Referenced by VART::Action::AddJointMover().
| void VART::JointMover::ModifyDofMovers | ( | DMModifier & | modifier | ) |
Modifies noisy dof movers.
Definition at line 155 of file jointmover.cpp.
References VART::DMModifier::Modify().
| void VART::JointMover::Move | ( | ) |
Moves the associated joint.
Definition at line 43 of file jointmover.cpp.
References VART::DofMover::goalTime, VART::DofMover::interpolatorPtr, and VART::DofMover::minimumDuration.
| void VART::JointMover::MultiplyTimes | ( | float | value | ) |
Changes starting/ending times of all dof movers.
| value | [in] multiplying factor. |
Multiplies "value" for starting and ending time, of every dof mover. This could be usefull for sequencing dof movers inside an action.
Definition at line 94 of file jointmover.cpp.
|
inline |
Sets the total movement duration (in seconds).
Definition at line 58 of file jointmover.h.
References duration.
|
inline |
Changes the associated interpolator.
Definition at line 64 of file jointmover.h.
References interpolatorPtr.
Referenced by VART::XmlJointAction::CreateJointMover(), and VART::XmlAction::LoadAnimation().
|
friend |
|
protected |
Definition at line 101 of file jointmover.h.
Referenced by CopyFrom().
|
protected |
Definition at line 98 of file jointmover.h.
Referenced by CopyFrom(), GetDuration(), and SetDuration().
|
static |
Definition at line 92 of file jointmover.h.
Referenced by VART::JointAction::Move(), and VART::Action::Move().
|
protected |
Definition at line 100 of file jointmover.h.
Referenced by CopyFrom(), GetInterpolator(), and SetInterpolator().
|
protected |
Associated joint.
Definition at line 97 of file jointmover.h.
Referenced by AttachToJoint(), CopyFrom(), and GetAttachedJoint().
|
protected |
Definition at line 99 of file jointmover.h.
Referenced by CopyFrom().
1.8.6