PathControl.h
PathControl & operator=(const PathControl &other)
Assignment operator.
Definition: PathControl.cpp:100
const Control * getControl(unsigned int index) const
Get the control located at index along the path. This is the control that gets applied to the state l...
Definition: PathControl.h:176
void print(std::ostream &out) const override
Print the path to a stream.
Definition: PathControl.cpp:134
Control * getControl(unsigned int index)
Get the control located at index along the path. This is the control that gets applied to the state l...
Definition: PathControl.h:169
void append(const base::State *state)
Append state to the end of the path; it is assumed state is the first state, so no control is applied...
Definition: PathControl.cpp:262
virtual void printAsMatrix(std::ostream &out) const
Print the path as a real-valued matrix where the i-th row represents the i-th state along the path...
Definition: PathControl.cpp:152
geometric::PathGeometric asGeometric() const
Convert this path into a geometric path (interpolation is performed and then states are copied) ...
Definition: PathControl.cpp:91
std::vector< Control * > controls_
The control applied at each state. This array contains one element less than the list of states...
Definition: PathControl.h:208
base::State * getState(unsigned int index)
Get the state located at index along the path.
Definition: PathControl.h:156
std::vector< Control * > & getControls()
Get the controls that make up the path (as a reference, so it can be modified, hence the function is ...
Definition: PathControl.h:143
const base::State * getState(unsigned int index) const
Get the state located at index along the path.
Definition: PathControl.h:162
bool randomValid(unsigned int attempts)
Set this path to a random valid segment. Sample attempts times for valid segments. Returns true on success.
Definition: PathControl.cpp:296
A shared pointer wrapper for ompl::base::SpaceInformation.
void interpolate()
Make the path such that all controls are applied for a single time step (computes intermediate states...
Definition: PathControl.cpp:187
std::size_t getControlCount() const
Get the number of controls applied along this path. This should be equal to getStateCount() - 1 unles...
Definition: PathControl.h:195
std::vector< double > controlDurations_
The duration of the control applied at each state. This array contains one element less than the list...
Definition: PathControl.h:212
A shared pointer wrapper for ompl::base::OptimizationObjective.
base::Cost cost(const base::OptimizationObjectivePtr &opt) const override
Not yet implemented.
Definition: PathControl.cpp:123
double length() const override
The path length (sum of control durations)
Definition: PathControl.cpp:129
std::vector< double > & getControlDurations()
Get the control durations used along the path (as a reference, so it can be modified, hence the function is not const)
Definition: PathControl.h:150
double getControlDuration(unsigned int index) const
Get the duration of the control at index, which gets applied to the state at index.
Definition: PathControl.h:182
std::size_t getStateCount() const
Get the number of states (way-points) that make up this path.
Definition: PathControl.h:188
void copyFrom(const PathControl &other)
Copy the content of a path to this one.
Definition: PathControl.cpp:108
Definition of a cost value. Can represent the cost of a motion or the cost of a state.
Definition: Cost.h:47
std::vector< base::State * > & getStates()
Get the states that make up the path (as a reference, so it can be modified, hence the function is no...
Definition: PathControl.h:136
std::vector< base::State * > states_
The list of states that make up the path.
Definition: PathControl.h:204