|
|
Uniform distribution of an cuboid space. More...
#include <RobotComponents/components/MotionPlanning/util/Samplers.h>
Public Types | |
| using | BoundsType = std::pair<RealType, RealType> |
| Type to pass the bounds of a dimension. | |
Public Member Functions | |
| template<class T = std::size_t> | |
| T | getDimensionality () const |
| Returns the cuboid's dimensionality. | |
| RealType | getVolume () const |
| Returns the cuboid's volume. | |
| template<class Iterator> | |
| bool | isInBounds (Iterator first) |
| Returns whether the range [first, first + dimensionality) is a point contained by the cuboid. | |
| template<class Iterator, class Generator> | |
| void | operator() (Iterator first, Generator &gen) |
| Fills the range [first, first + dimensionality) with an uniform sample of the cuboid. | |
| template<class Iterator> | |
| UniformCuboidDistribution (Iterator boundsFirst, Iterator boundsLast) | |
| Constructs a cuboid distribution with the bounds [boundsFirst, boundsLast). | |
Protected Attributes | |
| std::vector< std::uniform_real_distribution< RealType > > | spaceDist |
| Distributions for the dimensions of the cuboid. | |
| RealType | volume |
| The cuboid's volume. | |
Uniform distribution of an cuboid space.
Definition at line 223 of file Samplers.h.
| using BoundsType = std::pair<RealType, RealType> |
Type to pass the bounds of a dimension.
Definition at line 229 of file Samplers.h.
|
inline |
Constructs a cuboid distribution with the bounds [boundsFirst, boundsLast).
bounds.first is used as lower and bounds.second as upper bound.
| boundsFirst | The bounds for the first dimension. |
| boundsLast | One past the bounds for the last dimension. |
Definition at line 238 of file Samplers.h.
Returns the cuboid's dimensionality.
Definition at line 307 of file Samplers.h.
|
inline |
|
inline |
Returns whether the range [first, first + dimensionality) is a point contained by the cuboid.
[first, first + dimensionality) has to be a valid range. If not the behavior is undefined.
| first | The first value of the point. |
Definition at line 278 of file Samplers.h.
|
inline |
Fills the range [first, first + dimensionality) with an uniform sample of the cuboid.
[first, first + dimensionality) has to be a valid range. If not the behavior is undefined.
| first | The first value to fill. |
| gen | The used generator. |
Definition at line 262 of file Samplers.h.
|
protected |
Distributions for the dimensions of the cuboid.
Definition at line 320 of file Samplers.h.
|
protected |
The cuboid's volume.
Definition at line 316 of file Samplers.h.