Choreonoid
1.8
src
Body
BodyCollisionDetector.h
Go to the documentation of this file.
1
6
#ifndef CNOID_BODY_BODY_COLLISION_DETECTOR_H
7
#define CNOID_BODY_BODY_COLLISION_DETECTOR_H
8
9
#include <cnoid/CollisionDetector>
10
#include "exportdecl.h"
11
12
namespace
cnoid
{
13
14
class
Body;
15
class
Link;
16
17
class
CNOID_EXPORT
BodyCollisionDetector
18
{
19
public
:
20
BodyCollisionDetector
();
21
virtual
~
BodyCollisionDetector
();
22
23
void
setCollisionDetector(
CollisionDetector
* collisionDetector);
24
CollisionDetector
* collisionDetector();
25
26
void
clearBodies();
27
28
void
enableGeometryHandleMap(
bool
on);
29
stdx::optional<CollisionDetector::GeometryHandle> findGeometryHandle(
Link
* link);
30
31
void
addBody(
Body
* body,
bool
isSelfCollisionDetectionEnabled);
32
void
addBody(
Body
* body,
bool
isSelfCollisionDetectionEnabled,
33
std::function<
Referenced
*(
Link
* link,
CollisionDetector::GeometryHandle
geometry)> getObjectAssociatedWithLink);
34
bool
makeReady();
35
36
void
updatePositions();
37
void
updatePositions(std::function<
void
(
Referenced
*
object
,
Isometry3
*& out_position)> positionQuery);
38
39
void
detectCollisions(std::function<
void
(
const
CollisionPair
& collisionPair)> callback);
40
41
private
:
42
class
Impl;
43
Impl* impl;
44
};
45
46
}
47
48
#endif
cnoid::BodyCollisionDetector
Definition:
BodyCollisionDetector.h:17
cnoid::Isometry3
Eigen::Isometry3d Isometry3
Definition:
EigenTypes.h:73
cnoid
Definition:
AbstractSceneLoader.h:11
cnoid::CollisionDetector
Definition:
CollisionDetector.h:20
cnoid::CollisionPair
Definition:
CollisionDetector.h:72
cnoid::Referenced
Definition:
Referenced.h:54
cnoid::CollisionDetector::GeometryHandle
intptr_t GeometryHandle
Definition:
CollisionDetector.h:23
cnoid::Body
Definition:
Body.h:28
cnoid::Link
Definition:
Link.h:26
Generated by
1.8.17