|  | ReactPhysics3D
    v0.10.2
    C++ Physics engine library | 
This class represents a set of contact points between two bodies that all have a similar contact normal direction. More...
#include <include/reactphysics3d/collision/ContactManifold.h>
| Public Member Functions | |
| ContactManifold (Entity bodyEntity1, Entity bodyEntity2, Entity colliderEntity1, Entity colliderEntity2, uint32 contactPointsIndex, uint8 nbContactPoints) | |
| Constructor. | |
| Public Attributes | |
| uint32 | contactPointsIndex | 
| Index of the first contact point of the manifold in the array of contact points. | |
| Entity | bodyEntity1 | 
| Entity of the first body in contact. | |
| Entity | bodyEntity2 | 
| Entity of the second body in contact. | |
| Entity | colliderEntity1 | 
| Entity of the first collider in contact. | |
| Entity | colliderEntity2 | 
| Entity of the second collider in contact. | |
| uint8 | nbContactPoints | 
| Number of contacts in the cache. | |
| Vector3 | frictionVector1 | 
| First friction vector of the contact manifold. | |
| Vector3 | frictionVector2 | 
| Second friction vector of the contact manifold. | |
| decimal | frictionImpulse1 | 
| First friction constraint accumulated impulse. | |
| decimal | frictionImpulse2 | 
| Second friction constraint accumulated impulse. | |
| decimal | frictionTwistImpulse | 
| Twist friction constraint accumulated impulse. | |
| bool | isAlreadyInIsland | 
| True if the contact manifold has already been added into an island. | |
| Static Public Attributes | |
| static constexpr int | MAX_CONTACT_POINTS_IN_MANIFOLD = 4 | 
| Maximum number of contact points in a reduced contact manifold. | |
This class represents a set of contact points between two bodies that all have a similar contact normal direction.
Usually, there is a single contact manifold when two convex shapes are in contact. However, when a convex shape collides with a concave shape, there might be several contact manifolds with different normal directions. The contact manifold is implemented in a way to cache the contact points among the frames for better stability (warm starting of the contact solver)