ReactPhysics3D  v0.10.2
C++ Physics engine library
Loading...
Searching...
No Matches
reactphysics3d::NarrowPhaseInfoBatch Struct Reference

This structure collects all the potential collisions from the middle-phase algorithm that have to be tested during narrow-phase collision detection. More...

#include <include/reactphysics3d/collision/narrowphase/NarrowPhaseInfoBatch.h>

Classes

struct  NarrowPhaseInfo
 A potential collision between two colliders from the middle-phase algorithm that have to be tested during narrow-phase collision detection. More...
 

Public Member Functions

 NarrowPhaseInfoBatch (OverlappingPairs &overlappingPairs, MemoryAllocator &allocator)
 Constructor.
 
 ~NarrowPhaseInfoBatch ()
 Destructor.
 
void addNarrowPhaseInfo (uint64 pairId, Entity collider1, Entity collider2, CollisionShape *shape1, CollisionShape *shape2, const Transform &shape1Transform, const Transform &shape2Transform, bool needToReportContacts, LastFrameCollisionInfo *lastFrameInfo, MemoryAllocator &shapeAllocator)
 Add shapes to be tested during narrow-phase collision detection into the batch.
 
uint32 getNbObjects () const
 Return the number of objects in the batch.
 
void addContactPoint (uint32 index, const Vector3 &contactNormal, decimal penDepth, const Vector3 &localPt1, const Vector3 &localPt2)
 Add a new contact point.
 
void resetContactPoints (uint32 index)
 Reset the remaining contact points.
 
void reserveMemory ()
 
void clear ()
 Clear all the objects in the batch.
 

Public Attributes

Array< NarrowPhaseInfonarrowPhaseInfos
 For each collision test, we keep some meta data.
 

Detailed Description

This structure collects all the potential collisions from the middle-phase algorithm that have to be tested during narrow-phase collision detection.


The documentation for this struct was generated from the following files: