35 units::second_t t = 0_s;
38 units::meters_per_second_t velocity = 0_mps;
41 units::meters_per_second_squared_t acceleration = 0_mps_sq;
76 units::second_t
TotalTime()
const {
return m_totalTime; }
82 const std::vector<State>&
States()
const {
return m_states; }
136 std::vector<State> m_states;
137 units::second_t m_totalTime = 0_s;
#define WPILIB_DLLEXPORT
Definition: SymbolExports.h:36
Represents a 2D pose containing translational and rotational elements.
Definition: Pose2d.h:25
Represents a time-parameterized trajectory.
Definition: Trajectory.h:28
units::second_t TotalTime() const
Returns the overall duration of the trajectory.
Definition: Trajectory.h:76
Trajectory operator+(const Trajectory &other) const
Concatenates another trajectory to the current trajectory.
Trajectory TransformBy(const Transform2d &transform)
Transforms all poses in the trajectory by the given transform.
Trajectory RelativeTo(const Pose2d &pose)
Transforms all poses in the trajectory so that they are relative to the given pose.
bool operator==(const Trajectory &) const =default
Checks equality between this Trajectory and another object.
Trajectory(const std::vector< State > &states)
Constructs a trajectory from a vector of states.
State Sample(units::second_t t) const
Sample the trajectory at a point in time.
Pose2d InitialPose() const
Returns the initial pose of the trajectory.
Definition: Trajectory.h:128
const std::vector< State > & States() const
Return the states of the trajectory.
Definition: Trajectory.h:82
a class to store JSON values
Definition: json.h:2655
Definition: AprilTagFieldLayout.h:22
WPILIB_DLLEXPORT void from_json(const wpi::json &json, AprilTagFieldLayout &layout)
WPILIB_DLLEXPORT void to_json(wpi::json &json, const AprilTagFieldLayout &layout)
/file This file defines the SmallVector class.
Definition: AprilTagFieldLayout.h:18
Represents one point on the trajectory.
Definition: Trajectory.h:33
Pose2d pose
Definition: Trajectory.h:44
State Interpolate(State endValue, double i) const
Interpolates between two States.
bool operator==(const State &) const =default
Checks equality between this State and another object.