42#ifndef TESSERACT_COLLISION_FCL_DISCRETE_MANAGERS_H
43#define TESSERACT_COLLISION_FCL_DISCRETE_MANAGERS_H
54 using Ptr = std::shared_ptr<FCLDiscreteBVHManager>;
55 using ConstPtr = std::shared_ptr<const FCLDiscreteBVHManager>;
56 using UPtr = std::unique_ptr<FCLDiscreteBVHManager>;
57 using ConstUPtr = std::unique_ptr<const FCLDiscreteBVHManager>;
66 std::string
getName() const override final;
74 bool enabled = true) override final;
111 const std::
string& name2,
112 double collision_margin) override final;
#define vector(a, b, c)
Definition: FloatMath.inl:3227
This is a Tesseract link collision object wrapper which add items specific to tesseract....
Definition: fcl_utils.h:79
A FCL implementation of the discrete contact manager.
Definition: fcl_discrete_managers.h:52
void contactTest(ContactResultMap &collisions, const ContactRequest &request) override final
Perform a contact test for all objects based.
Definition: fcl_discrete_managers.cpp:314
const tesseract_common::VectorIsometry3d & getCollisionObjectGeometriesTransforms(const std::string &name) const override final
Get a collision objects collision geometries transforms.
Definition: fcl_discrete_managers.cpp:99
Link2COW link2cow_
A map of all (static and active) collision objects being managed.
Definition: fcl_discrete_managers.h:137
void setCollisionObjectsTransform(const std::string &name, const Eigen::Isometry3d &pose) override final
Set a single collision object's transforms.
Definition: fcl_discrete_managers.cpp:176
IsContactAllowedFn getIsContactAllowedFn() const override final
Get the active function for determining if two links are allowed to be in collision.
Definition: fcl_discrete_managers.cpp:312
void setDefaultCollisionMarginData(double default_collision_margin) override final
Set the default collision margin.
Definition: fcl_discrete_managers.cpp:296
bool removeCollisionObject(const std::string &name) override final
Remove an object from the checker.
Definition: fcl_discrete_managers.cpp:111
std::vector< std::string > active_
A list of the active collision objects.
Definition: fcl_discrete_managers.h:138
void setActiveCollisionObjects(const std::vector< std::string > &names) override final
Set which collision objects can move.
Definition: fcl_discrete_managers.cpp:276
std::size_t fcl_co_count_
The number fcl collision objects.
Definition: fcl_discrete_managers.h:142
std::shared_ptr< const FCLDiscreteBVHManager > ConstPtr
Definition: fcl_discrete_managers.h:55
FCLDiscreteBVHManager & operator=(FCLDiscreteBVHManager &&)=delete
std::string name_
Definition: fcl_discrete_managers.h:129
std::unique_ptr< fcl::BroadPhaseCollisionManagerd > static_manager_
Broad-phase Collision Manager for active collision objects.
Definition: fcl_discrete_managers.h:132
void onCollisionMarginDataChanged()
This function will update internal data when margin data has changed.
Definition: fcl_discrete_managers.cpp:370
std::unique_ptr< const FCLDiscreteBVHManager > ConstUPtr
Definition: fcl_discrete_managers.h:57
std::unique_ptr< fcl::BroadPhaseCollisionManagerd > dynamic_manager_
Broad-phase Collision Manager for active collision objects.
Definition: fcl_discrete_managers.h:135
std::shared_ptr< FCLDiscreteBVHManager > Ptr
Definition: fcl_discrete_managers.h:54
const CollisionShapesConst & getCollisionObjectGeometries(const std::string &name) const override final
Get a collision objects collision geometries.
Definition: fcl_discrete_managers.cpp:91
IsContactAllowedFn fn_
The is allowed collision function.
Definition: fcl_discrete_managers.h:141
FCLDiscreteBVHManager & operator=(const FCLDiscreteBVHManager &)=delete
FCLDiscreteBVHManager(FCLDiscreteBVHManager &&)=delete
const CollisionMarginData & getCollisionMarginData() const override final
Get the contact distance threshold.
Definition: fcl_discrete_managers.cpp:310
const std::vector< std::string > & getActiveCollisionObjects() const override final
Get which collision objects can move.
Definition: fcl_discrete_managers.cpp:288
DiscreteContactManager::UPtr clone() const override final
Clone the manager.
Definition: fcl_discrete_managers.cpp:58
std::vector< CollisionObjectRawPtr > dynamic_update_
This is used to store dynamic collision objects to update.
Definition: fcl_discrete_managers.h:148
std::vector< std::string > collision_objects_
A list of the collision objects.
Definition: fcl_discrete_managers.h:139
std::unique_ptr< FCLDiscreteBVHManager > UPtr
Definition: fcl_discrete_managers.h:56
void setPairCollisionMarginData(const std::string &name1, const std::string &name2, double collision_margin) override final
Set the margin for a given contact pair.
Definition: fcl_discrete_managers.cpp:302
bool hasCollisionObject(const std::string &name) const override final
Find if a collision object already exists.
Definition: fcl_discrete_managers.cpp:106
bool addCollisionObject(const std::string &name, const int &mask_id, const CollisionShapesConst &shapes, const tesseract_common::VectorIsometry3d &shape_poses, bool enabled=true) override final
Add a object to the checker.
Definition: fcl_discrete_managers.cpp:72
void setIsContactAllowedFn(IsContactAllowedFn fn) override final
Set the active function for determining if two links are allowed to be in collision.
Definition: fcl_discrete_managers.cpp:311
bool enableCollisionObject(const std::string &name) override final
Enable an object.
Definition: fcl_discrete_managers.cpp:145
std::string getName() const override final
Get the name of the contact manager.
Definition: fcl_discrete_managers.cpp:56
~FCLDiscreteBVHManager() override=default
std::vector< CollisionObjectRawPtr > static_update_
This is used to store static collision objects to update.
Definition: fcl_discrete_managers.h:145
bool isCollisionObjectEnabled(const std::string &name) const override final
Check if collision object is enabled.
Definition: fcl_discrete_managers.cpp:167
const std::vector< std::string > & getCollisionObjects() const override final
Get all collision objects.
Definition: fcl_discrete_managers.cpp:274
FCLDiscreteBVHManager(const FCLDiscreteBVHManager &)=delete
CollisionMarginData collision_margin_data_
The contact distance threshold.
Definition: fcl_discrete_managers.h:140
void setCollisionMarginData(CollisionMarginData collision_margin_data, CollisionMarginOverrideType override_type=CollisionMarginOverrideType::REPLACE) override final
Set the contact distance thresholds for which collision should be considered on a per pair basis.
Definition: fcl_discrete_managers.cpp:289
bool disableCollisionObject(const std::string &name) override final
Disable an object.
Definition: fcl_discrete_managers.cpp:156
Stores information about how the margins allowed between collision objects.
Definition: collision_margin_data.h:74
Tesseract ROS FCL Utility Functions.
Definition: fcl_collision_object_wrapper.h:36
std::map< std::string, COW::Ptr > Link2COW
Definition: fcl_utils.h:194
std::vector< tesseract_geometry::Geometry::ConstPtr > CollisionShapesConst
Definition: types.h:47
std::function< bool(const std::string &, const std::string &)> IsContactAllowedFn
Should return true if contact allowed, otherwise false.
Definition: types.h:59
Definition: allowed_collision_matrix.h:16
CollisionMarginOverrideType
Identifies how the provided contact margin data should be applied.
Definition: collision_margin_data.h:46
auto pose
Definition: tesseract_environment_collision.cpp:118
m name
Definition: tesseract_scene_graph_link_unit.cpp:77