43 namespace ompl
71 ~RRT() override;
79 void clear() override;
90 goalBias_ = goalBias;
96 return goalBias_;
103 return addIntermediateStates_;
110 addIntermediateStates_ = addIntermediateStates;
120 OMPL_WARN("Calling setNearestNeighbors will clear all states.");
122 nn_ = std::make_shared<NN<Motion *>>();
126 void setup() override;
136 Motion() = default;
144 ~Motion() = default;
160 void freeMemory();
Random number generation. An instance of this class cannot be used by multiple threads at once (membe...
Object containing planner generated vertex and edge data. It is assumed that all vertices are unique,...
Encapsulate a termination condition for a motion planner. Planners will call operator() to decide whe...
The space information for which planning is done.
A shared pointer wrapper for ompl::base::SpaceInformation.
A shared pointer wrapper for ompl::control::DirectedControlSampler.
Motion(const SpaceInformation *si)
Constructor that allocates memory for the state and the control.
unsigned int steps
The number of steps the control is applied for.
base::State * state
The state contained by the motion.
Control * control
The control contained by the motion.
Motion * parent
The parent motion in the exploration tree.
bool getIntermediateStates() const
Return true if the intermediate states generated along motions are to be added to the tree itself.
The fraction of time the goal is picked as the state to expand towards (if such a state is available)
Free the memory allocated by this planner.
const SpaceInformation * siC_
The base::SpaceInformation cast as control::SpaceInformation, for convenience.
Set a different nearest neighbors datastructure.
void setIntermediateStates(bool addIntermediateStates)
Specify whether the intermediate states generated along motions are to be added to the tree itself.
double distanceFunction(const Motion *a, const Motion *b) const
Compute distance between motions (actually distance between contained states)
Flag indicating whether intermediate states are added to the built tree of motions.
base::PlannerStatus solve(const base::PlannerTerminationCondition &ptc) override
Continue solving for some amount of time. Return true if solution was found.
double getGoalBias() const
Get the goal bias the planner is using.
void clear() override
Clear datastructures. Call this function if the input data to the planner has changed and you do not ...
void getPlannerData(base::PlannerData &data) const override
Get information about the current run of the motion planner. Repeated calls to this function will upd...
Motion * lastGoalMotion_
The most recent goal motion. Used for PlannerData computation.
void setup() override
Perform extra configuration steps, if needed. This call will also issue a call to ompl::base::SpaceIn...
std::shared_ptr< NearestNeighbors< Motion * > > nn_
A nearest-neighbors datastructure containing the tree of motions.
Space information containing necessary information for planning with controls. setup() needs to be ca...