StateSampler.h
virtual void addSampler(const StateSamplerPtr &sampler, double weightImportance)
Add a sampler as part of the new compound sampler. This sampler is used to sample part of the compoun...
Definition: StateSampler.cpp:40
Construct a sampler that samples only within a subspace of the space.
Definition: StateSampler.h:217
Representation of a space in which planning can be performed. Topology specific sampling,...
Definition: StateSpace.h:134
std::vector< StateSamplerPtr > samplers_
The samplers that are composed.
Definition: StateSampler.h:206
double weight_
The weigth factor to multiply distance and stdDev when sampling in the vicinity of a state.
Definition: StateSampler.h:240
~CompoundStateSampler() override=default
Destructor. This frees the added samplers as well.
std::vector< std::string > subspaces_
The names of common subspaces between space_ and subspace_; these are the ones copied after sampling ...
Definition: StateSampler.h:244
std::vector< double > weightImportance_
The weight of each sampler (used when sampling near a state)
Definition: StateSampler.h:209
void sampleUniformNear(State *state, const State *near, double distance) override
Sample a state near another, within a neighborhood controlled by a distance parameter.
Definition: StateSampler.cpp:97
SubspaceStateSampler(const StateSpace *space, const StateSpace *subspace, double weight)
Construct a sampler for space but only sample components common to subspace. Use weight as a multipli...
Definition: StateSampler.cpp:73
std::function< StateSamplerPtr(const StateSpace *)> StateSamplerAllocator
Definition of a function that can allocate a state sampler.
Definition: StateSampler.h:255
void sampleGaussian(State *state, const State *mean, double stdDev) override
Call sampleGaussian for each of the subspace states with stdDev scaled by the corresponding subspace ...
Definition: StateSampler.cpp:65
A shared pointer wrapper for ompl::base::StateSampler.
virtual void sampleGaussian(State *state, const State *mean, double stdDev)=0
Sample a state using a Gaussian distribution with given mean and standard deviation (stdDev).
void sampleGaussian(State *state, const State *mean, double stdDev) override
Sample a state using a Gaussian distribution with given mean and standard deviation (stdDev).
Definition: StateSampler.cpp:104
virtual void sampleUniformNear(State *state, const State *near, double distance)=0
Sample a state near another, within a neighborhood controlled by a distance parameter.
void sampleUniformNear(State *state, const State *near, double distance) override
Call sampleUniformNear for each of the subspace states with distance scaled by the corresponding subs...
Definition: StateSampler.cpp:54