mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-28 02:11:43 +00:00
Add getter for initial pose in Trajectory (#2180)
This commit is contained in:
committed by
Peter Johnson
parent
71a22861eb
commit
635882a9f7
@@ -105,6 +105,13 @@ class Trajectory {
|
||||
*/
|
||||
State Sample(units::second_t t) const;
|
||||
|
||||
/**
|
||||
* Returns the initial pose of the trajectory.
|
||||
*
|
||||
* @return The initial pose of the trajectory.
|
||||
*/
|
||||
Pose2d InitialPose() const { return Sample(0_s).pose; }
|
||||
|
||||
private:
|
||||
std::vector<State> m_states;
|
||||
units::second_t m_totalTime;
|
||||
|
||||
Reference in New Issue
Block a user