Struct Contact

Struct Documentation

struct Contact

Contact information returned by collision.

Public Functions

inline Contact()

Default constructor.

inline Contact(const CollisionGeometry *o1_, const CollisionGeometry *o2_, int b1_, int b2_)
inline Contact(const CollisionGeometry *o1_, const CollisionGeometry *o2_, int b1_, int b2_, const Vec3f &pos_, const Vec3f &normal_, FCL_REAL depth_)
inline bool operator<(const Contact &other) const
inline bool operator==(const Contact &other) const
inline bool operator!=(const Contact &other) const

Public Members

const CollisionGeometry *o1

collision object 1

const CollisionGeometry *o2

collision object 2

int b1

contact primitive in object 1 if object 1 is mesh or point cloud, it is the triangle or point id if object 1 is geometry shape, it is NONE (-1), if object 1 is octree, it is the id of the cell

int b2

contact primitive in object 2 if object 2 is mesh or point cloud, it is the triangle or point id if object 2 is geometry shape, it is NONE (-1), if object 2 is octree, it is the id of the cell

Vec3f normal

contact normal, pointing from o1 to o2

Vec3f pos

contact position, in world space

FCL_REAL penetration_depth

penetration depth

Public Static Attributes

static const int NONE = -1

invalid contact primitive information