moveit2
The MoveIt Motion Planning Framework for ROS 2.
|
This class assists in the generation of a ConstraintSampler for a particular group from a moveit_msgs::msg::Constraints. More...
#include <constraint_sampler_manager.h>
Public Member Functions | |
ConstraintSamplerManager () | |
Empty constructor. | |
void | registerSamplerAllocator (const ConstraintSamplerAllocatorPtr &sa) |
Allows the user to specify an alternate ConstraintSamplerAllocation. | |
ConstraintSamplerPtr | selectSampler (const planning_scene::PlanningSceneConstPtr &scene, const std::string &group_name, const moveit_msgs::msg::Constraints &constr) const |
Selects among the potential sampler allocators. | |
Static Public Member Functions | |
static ConstraintSamplerPtr | selectDefaultSampler (const planning_scene::PlanningSceneConstPtr &scene, const std::string &group_name, const moveit_msgs::msg::Constraints &constr) |
Default logic to select a ConstraintSampler given a constraints message. | |
This class assists in the generation of a ConstraintSampler for a particular group from a moveit_msgs::msg::Constraints.
It contains logic that will generate either a JointConstraintSampler, an IKConstraintSampler, or a UnionConstraintSampler depending on the contents of the Constraints message and the group in question.
Definition at line 59 of file constraint_sampler_manager.h.
|
inline |
Empty constructor.
Definition at line 66 of file constraint_sampler_manager.h.
|
inline |
Allows the user to specify an alternate ConstraintSamplerAllocation.
sa | The constraint sampler allocator that will be used |
Definition at line 74 of file constraint_sampler_manager.h.
|
static |
Default logic to select a ConstraintSampler given a constraints message.
This function will generate a sampler using the joint_constraint, position_constraint, and orientation_constraint vectors from the Constraints argument. The type of constraint sampler that is produced depends on which constraint vectors have been populated. The following rules are applied:
scene | The planning scene that will be used to create the ConstraintSampler |
group_name | The group name for which to create a sampler |
constr | The set of constraints for which to create a sampler |
Definition at line 69 of file constraint_sampler_manager.cpp.
ConstraintSamplerPtr constraint_samplers::ConstraintSamplerManager::selectSampler | ( | const planning_scene::PlanningSceneConstPtr & | scene, |
const std::string & | group_name, | ||
const moveit_msgs::msg::Constraints & | constr | ||
) | const |
Selects among the potential sampler allocators.
This function will iterate through the constraint sampler allocators, trying to find one that can service the constraints. The first one that can service the request will be called. If no allocators can service the Constraints, or there are no allocators, the selectDefaultSampler will be called.
scene | The planning scene that will be passed into the constraint sampler |
group_name | The group name for which to allocate the constraint sampler |
constr | The constraints |
Definition at line 55 of file constraint_sampler_manager.cpp.