diff --git a/cmake b/cmake index 332976cc4..3d6176d43 160000 --- a/cmake +++ b/cmake @@ -1 +1 @@ -Subproject commit 332976cc4d5305256c79a479e55ad7ab2ecc42f1 +Subproject commit 3d6176d439963702d97b82555e3007de05a4e6a4 diff --git a/python/broadphase/broadphase_callbacks.hh b/python/broadphase/broadphase_callbacks.hh index 61f4fd346..fd21c4cae 100644 --- a/python/broadphase/broadphase_callbacks.hh +++ b/python/broadphase/broadphase_callbacks.hh @@ -74,10 +74,16 @@ struct CollisionCallBackBaseWrapper : CollisionCallBackBase, struct DistanceCallBackBaseWrapper : DistanceCallBackBase, bp::wrapper { typedef DistanceCallBackBase Base; + typedef DistanceCallBackBaseWrapper Self; void init() { this->get_override("init")(); } - bool distance(CollisionObject* o1, CollisionObject* o2) { - return this->get_override("distance")(o1, o2); + bool distance(CollisionObject* o1, CollisionObject* o2, + Eigen::Matrix& dist) { + return distance(o1, o2, dist.coeffRef(0, 0)); + } + + bool distance(CollisionObject* o1, CollisionObject* o2, FCL_REAL& dist) { + return this->get_override("distance")(o1, o2, dist); } static void expose() { @@ -85,7 +91,11 @@ struct DistanceCallBackBaseWrapper : DistanceCallBackBase, "DistanceCallBackBase", bp::no_init) .def("init", bp::pure_virtual(&Base::init), doxygen::member_func_doc(&Base::init)) - .def("distance", bp::pure_virtual(&Base::distance), + .def("distance", + bp::pure_virtual( + static_cast & dist)>(&Self::distance)), doxygen::member_func_doc(&Base::distance)) .def("__call__", &Base::operator(), doxygen::member_func_doc(&Base::operator()));