![]() |
RobWorkProject
23.9.11-
|
random sampling of points and orientations close to the surface of a geometry. More...
#include <SurfacePoseSampler.hpp>
Inherits PoseSampler.
Public Types | |
| typedef rw::core::Ptr< SurfacePoseSampler > | Ptr |
Public Types inherited from PoseSampler | |
| typedef rw::core::Ptr< PoseSampler > | Ptr |
Public Member Functions | |
| SurfacePoseSampler (rw::geometry::Geometry::Ptr geom) | |
| SurfacePoseSampler (const std::vector< rw::geometry::Geometry::Ptr > &geoms) | |
| void | init (rw::geometry::Geometry::Ptr geom) |
| rw::math::Transform3D | sample () |
| void | setBoundsD (double minD, double maxD) |
| void | setRandomRotationEnabled (bool enabled) |
| void | setRandomPositionEnabled (bool enabled) |
| void | setZAxisDirectionEnabled (bool enabled) |
| void | setZAxisDirection (const rw::math::Vector3D<> &dir) |
random sampling of points and orientations close to the surface of a geometry.
A point p on the surface is randomly choosen.
A rotation rot is randomly generated.
A random distance d in the interval [minD, maxD] is generated
The position pos is calculated as \( pos = p - rot*(0,0,d)^T \)
The random pose X is thus \( X = (pos, rot) \) Optionally a random rotation of X can be generated such that z-axis of rot is not allways pointing toward the surface.