16 #ifndef SURGSIM_BLOCKS_POSEINTERPOLATOR_H 17 #define SURGSIM_BLOCKS_POSEINTERPOLATOR_H 60 void setTarget(std::shared_ptr<SurgSim::Framework::SceneElement> target);
64 void setDuration(
double t);
68 double getDuration()
const;
72 void setLoop(
bool val);
80 void setPingPong(
bool val);
83 bool isPingPong()
const;
86 virtual void update(
double dt)
override;
100 std::shared_ptr<SurgSim::Framework::SceneElement>
m_target;
115 virtual bool doWakeUp()
override;
118 virtual bool doInitialize()
override;
Definition: DriveElementFromInputBehavior.cpp:27
bool m_loop
Whether to loop.
Definition: PoseInterpolator.h:112
SurgSim::DataStructures::OptionalValue< SurgSim::Math::RigidTransform3d > m_optionalStartPose
Optional value to take the from rigid transform.
Definition: PoseInterpolator.h:91
string(TOUPPER ${DEVICE}DEVICE_UPPER_CASE) option(BUILD_DEVICE_ $
Definition: CMakeLists.txt:35
SurgSim::Math::RigidTransform3d m_startingPose
Target of the interpolation.
Definition: PoseInterpolator.h:94
bool m_pingpong
Whether to pingpong.
Definition: PoseInterpolator.h:109
std::shared_ptr< SurgSim::Framework::SceneElement > m_target
Target for the interpolated RigidTransform.
Definition: PoseInterpolator.h:100
Eigen::Transform< double, 3, Eigen::Isometry > RigidTransform3d
A 3D rigid (isometric) transform, represented as doubles.
Definition: RigidTransform.h:46
SurgSim::Math::RigidTransform3d m_endingPose
Start of the interpolation.
Definition: PoseInterpolator.h:97
Behaviors perform actions.
Definition: Behavior.h:40
Perform linear interpolation on two poses.
Definition: PoseInterpolator.h:39
double m_duration
Duration of the interpolation.
Definition: PoseInterpolator.h:103
double m_currentTime
How far through the interpolation we are.
Definition: PoseInterpolator.h:106