Go to the documentation of this file.
26 #ifndef TESSERACT_VISUALIZATION_TRAJECTORY_PLAYER_H
27 #define TESSERACT_VISUALIZATION_TRAJECTORY_PLAYER_H
39 class TrajectoryInterpolator;
142 std::chrono::time_point<std::chrono::high_resolution_clock>
start_time_;
147 #endif // TESSERACT_VISUALIZATION_TRAJECTORY_PLAYER_H
std::chrono::system_clock::duration duration
double trajectoryDurationEnd() const
Get the trajectory duration at the end state.
tesseract_common::JointState setCurrentDuration(double duration)
Set the current time for the player by duration.
void enableLoop(bool loop)
Enable looping playback of the trajectory.
long size() const
The size of the tajectory.
Enables the ability to play a trajectory provided by the set program.
double currentDuration() const
Get the current duration populated by the last call to getNext()
#define TESSERACT_COMMON_IGNORE_WARNINGS_PUSH
void reset()
Reset the state of the trajectory player.
void setTrajectory(const tesseract_common::JointTrajectory &trajectory)
Set the the trajectory for the trajectory player.
tesseract_common::JointState setCurrentDurationByIndex(long index)
Set the current time for the player by index of the input trajectoy.
bool isFinished() const
Check if the player has the reached the end of the trajectory.
tesseract_common::JointState getByIndex(long index) const
Get move instruction by index.
bool isLoopEnabled() const
Get if looping playback is enabled.
tesseract_common::JointState getNext()
Get the next move instruction from the player.
void setScale(double scale)
Set the scale factor for the play back of the trajectory.
TrajectoryPlayer & operator=(const TrajectoryPlayer &)=delete
double trajectoryDurationBegin() const
Get the trajectory duration at the begin state.
double trajectory_duration_start_
double trajectory_duration_end_
std::unique_ptr< TrajectoryInterpolator > trajectory_
std::chrono::time_point< std::chrono::high_resolution_clock > start_time_