Go to the documentation of this file.
5 #ifndef HPP_FCL_SERIALIZATION_COLLISION_DATA_H
6 #define HPP_FCL_SERIALIZATION_COLLISION_DATA_H
12 namespace serialization {
14 template <
class Archive>
16 const unsigned int ) {
17 ar& make_nvp(
"b1", contact.
b1);
18 ar& make_nvp(
"b2", contact.
b2);
19 ar& make_nvp(
"normal", contact.
normal);
20 ar& make_nvp(
"pos", contact.
pos);
24 template <
class Archive>
26 const unsigned int ) {
27 ar >> make_nvp(
"b1", contact.
b1);
28 ar >> make_nvp(
"b2", contact.
b2);
29 ar >> make_nvp(
"normal", contact.
normal);
30 ar >> make_nvp(
"pos", contact.
pos);
38 template <
class Archive>
40 const unsigned int ) {
45 ar& make_nvp(
"enable_cached_gjk_guess",
49 ar& make_nvp(
"cached_support_func_guess",
54 template <
class Archive>
56 const unsigned int ) {
58 ar& make_nvp(
"cached_support_func_guess",
62 template <
class Archive>
64 const unsigned int ) {
66 boost::serialization::base_object<hpp::fcl::QueryRequest>(
70 ar& make_nvp(
"enable_distance_lower_bound",
76 template <
class Archive>
78 const unsigned int ) {
79 ar& make_nvp(
"base", boost::serialization::base_object<hpp::fcl::QueryResult>(
81 ar& make_nvp(
"contacts", collision_result.
getContacts());
85 template <
class Archive>
87 const unsigned int ) {
89 make_nvp(
"base", boost::serialization::base_object<hpp::fcl::QueryResult>(
91 std::vector<hpp::fcl::Contact> contacts;
92 ar >> make_nvp(
"contacts", contacts);
93 collision_result.
clear();
94 for (
size_t k = 0; k < contacts.size(); ++k)
101 template <
class Archive>
103 const unsigned int ) {
105 boost::serialization::base_object<hpp::fcl::QueryRequest>(
108 ar& make_nvp(
"rel_err", distance_request.
rel_err);
109 ar& make_nvp(
"abs_err", distance_request.
abs_err);
112 template <
class Archive>
114 const unsigned int ) {
115 ar& make_nvp(
"base", boost::serialization::base_object<hpp::fcl::QueryResult>(
117 ar& make_nvp(
"min_distance", distance_result.
min_distance);
118 ar& make_nvp(
"nearest_points", make_array(distance_result.
nearest_points, 2));
119 ar& make_nvp(
"normal", distance_result.
normal);
120 ar& make_nvp(
"b1", distance_result.
b1);
121 ar& make_nvp(
"b2", distance_result.
b2);
124 template <
class Archive>
126 const unsigned int ) {
128 make_nvp(
"base", boost::serialization::base_object<hpp::fcl::QueryResult>(
130 ar >> make_nvp(
"min_distance", distance_result.
min_distance);
132 make_nvp(
"nearest_points", make_array(distance_result.
nearest_points, 2));
133 ar >> make_nvp(
"normal", distance_result.
normal);
134 ar >> make_nvp(
"b1", distance_result.
b1);
135 ar >> make_nvp(
"b2", distance_result.
b2);
136 distance_result.
o1 = NULL;
137 distance_result.
o2 = NULL;
145 #endif // ifndef HPP_FCL_SERIALIZATION_COLLISION_DATA_H
int b2
information about the nearest point in object 2 if object 2 is mesh or point cloud,...
void addContact(const Contact &c)
add one contact into result structure
FCL_REAL break_distance
Distance below which bounding volumes are broken down. See Collision.
#define HPP_FCL_COMPILER_DIAGNOSTIC_IGNORED_DEPRECECATED_DECLARATIONS
Vec3f nearest_points[2]
nearest points
bool enable_distance_lower_bound
Whether a lower bound on distance is returned when objects are disjoint.
#define HPP_FCL_SERIALIZATION_SPLIT(Type)
base class for all query results
const CollisionGeometry * o1
collision object 1
GJKInitialGuess gjk_initial_guess
void load(Archive &ar, hpp::fcl::BVSplitter< BV > &splitter_, const unsigned int)
bool enable_timings
enable timings when performing collision/distance request
Vec3f normal
In case both objects are in collision, store the normal.
int b1
information about the nearest point in object 1 if object 1 is mesh or point cloud,...
FCL_REAL security_margin
Distance below which objects are considered in collision. See Collision.
bool enable_contact
whether the contact information (normal, penetration depth and contact position) will return
Vec3f cached_gjk_guess
the gjk initial guess set by user
#define HPP_FCL_COMPILER_DIAGNOSTIC_PUSH
void clear()
clear the results obtained
request to the collision algorithm
Vec3f cached_gjk_guess
stores the last GJK ray when relevant.
FCL_REAL min_distance
minimum distance between two objects. if two objects are in collision, min_distance <= 0.
bool enable_cached_gjk_guess
whether enable gjk initial guess @Deprecated Use gjk_initial_guess instead
size_t num_max_contacts
The maximum number of contacts will return.
support_func_guess_t cached_support_func_guess
the support function initial guess set by user
request to the distance computation
FCL_REAL rel_err
error threshold for approximate distance
const CollisionGeometry * o2
collision object 2
#define HPP_FCL_COMPILER_DIAGNOSTIC_POP
void serialize(Archive &ar, hpp::fcl::AABB &aabb, const unsigned int)
base class for all query requests
bool enable_nearest_points
whether to return the nearest points
void getContacts(std::vector< Contact > &contacts_) const
get all the contacts
support_func_guess_t cached_support_func_guess
stores the last support function vertex index, when relevant.
void save(Archive &ar, const hpp::fcl::BVSplitter< BV > &splitter_, const unsigned int)
FCL_REAL distance_lower_bound
hpp-fcl
Author(s):
autogenerated on Fri Aug 2 2024 02:45:13