Cheetah Software
1.0
|
#include <CollisionMesh.h>
Public Member Functions | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW | CollisionMesh (const T &mu, const T &restitution, const T &grid, const Vec3< T > &left_corner_loc, const DMat< T > &height_map) |
virtual | ~CollisionMesh () |
virtual bool | ContactDetection (const Vec3< T > &cp_pos, T &penetration, Mat3< T > &cp_frame) |
Public Member Functions inherited from Collision< T > | |
Collision (const T &mu, const T &resti) | |
virtual | ~Collision () |
const T & | getFrictionCoeff () |
const T & | getRestitutionCoeff () |
Private Attributes | |
T | _size [3] |
Vec3< T > | _left_corner_loc |
DMat< T > | _height_map |
T | _grid |
T | _x_max |
T | _y_max |
Additional Inherited Members | |
Protected Attributes inherited from Collision< T > | |
T | _mu |
T | _restitution_coeff |
Class to represent box collision
Definition at line 17 of file CollisionMesh.h.
|
inline |
Construct a new collision Mesh
mu | : coefficient of friction |
restitution | : rebounding ratio (v+/v-) |
grid | : grid size (meter) of the given height map |
left_corner_loc | : global location of left bottom edge of the height map |
height_map | : Height map of mesh |
Definition at line 30 of file CollisionMesh.h.
References CollisionMesh< T >::_grid, CollisionMesh< T >::_height_map, CollisionMesh< T >::_x_max, and CollisionMesh< T >::_y_max.
|
inlinevirtual |
Definition at line 40 of file CollisionMesh.h.
References CollisionMesh< T >::ContactDetection().
|
virtual |
check whether the contact happens or not cp_frame let you know which direction is normal (z) and which directions are x and y. The frame is basically contact coordinate w.r.t global.
Implements Collision< T >.
Definition at line 9 of file CollisionMesh.cpp.
|
private |
Definition at line 50 of file CollisionMesh.h.
|
private |
Definition at line 48 of file CollisionMesh.h.
|
private |
Definition at line 47 of file CollisionMesh.h.
|
private |
Definition at line 45 of file CollisionMesh.h.
|
private |
Definition at line 51 of file CollisionMesh.h.
|
private |
Definition at line 52 of file CollisionMesh.h.