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();
void getPlannerData(base::PlannerData &data) const override
Get information about the current run of the motion planner. Repeated calls to this function will upd...
Random number generation. An instance of this class cannot be used by multiple threads at once (membe...
base::PlannerStatus solve(const base::PlannerTerminationCondition &ptc) override
Continue solving for some amount of time. Return true if solution was found.
const SpaceInformation * siC_
The base::SpaceInformation cast as control::SpaceInformation, for convenience.
Flag indicating whether intermediate states are added to the built tree of motions.
A shared pointer wrapper for ompl::base::SpaceInformation.
Control * control
The control contained by the motion.
Motion(const SpaceInformation *si)
Constructor that allocates memory for the state and the control.
double getGoalBias() const
Get the goal bias the planner is using.
Set a different nearest neighbors datastructure.
The fraction of time the goal is picked as the state to expand towards (if such a state is available)
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...
A class to store the exit status of Planner::solve()
Motion * parent
The parent motion in the exploration tree.
void clear() override
Clear datastructures. Call this function if the input data to the planner has changed and you do not ...
bool getIntermediateStates() const
Return true if the intermediate states generated along motions are to be added to the tree itself.
std::shared_ptr< NearestNeighbors< Motion * > > nn_
A nearest-neighbors datastructure containing the tree of motions.
void setIntermediateStates(bool addIntermediateStates)
Specify whether the intermediate states generated along motions are to be added to the tree itself.
Space information containing necessary information for planning with controls. setup() needs to be ca...
A shared pointer wrapper for ompl::control::DirectedControlSampler.
The space information for which planning is done.
double distanceFunction(const Motion *a, const Motion *b) const
Compute distance between motions (actually distance between contained states)
unsigned int steps
The number of steps the control is applied for.
base::State * state
The state contained by the motion.
Motion * lastGoalMotion_
The most recent goal motion. Used for PlannerData computation.
Free the memory allocated by this planner.
void setup() override
Perform extra configuration steps, if needed. This call will also issue a call to ompl::base::SpaceIn...