Jolt Physics
A multi core friendly Game Physics Engine
|
#include <CollisionGroup.h>
Public Types | |
using | GroupID = uint32 |
using | SubGroupID = uint32 |
Public Member Functions | |
CollisionGroup ()=default | |
Default constructor. More... | |
CollisionGroup (const GroupFilter *inFilter, GroupID inGroupID, SubGroupID inSubGroupID) | |
Construct with all properties. More... | |
void | SetGroupFilter (const GroupFilter *inFilter) |
Set the collision group filter. More... | |
const GroupFilter * | GetGroupFilter () const |
Get the collision group filter. More... | |
void | SetGroupID (GroupID inID) |
Set the main group id for this object. More... | |
GroupID | GetGroupID () const |
void | SetSubGroupID (SubGroupID inID) |
Add this object to a sub group. More... | |
SubGroupID | GetSubGroupID () const |
bool | CanCollide (const CollisionGroup &inOther) const |
Check if this object collides with another object. More... | |
void | SaveBinaryState (StreamOut &inStream) const |
Saves the state of this object in binary form to inStream. Does not save group filter. More... | |
void | RestoreBinaryState (StreamIn &inStream) |
Restore the state of this object from inStream. Does not save group filter. More... | |
Static Public Attributes | |
static const GroupID | cInvalidGroup = ~GroupID(0) |
static const SubGroupID | cInvalidSubGroup = ~SubGroupID(0) |
Two objects collide with each other if:
using CollisionGroup::GroupID = uint32 |
using CollisionGroup::SubGroupID = uint32 |
|
default |
Default constructor.
|
inline |
Construct with all properties.
|
inline |
Check if this object collides with another object.
|
inline |
Get the collision group filter.
|
inline |
|
inline |
void CollisionGroup::RestoreBinaryState | ( | StreamIn & | inStream | ) |
Restore the state of this object from inStream. Does not save group filter.
void CollisionGroup::SaveBinaryState | ( | StreamOut & | inStream | ) | const |
Saves the state of this object in binary form to inStream. Does not save group filter.
|
inline |
Set the collision group filter.
|
inline |
Set the main group id for this object.
|
inline |
Add this object to a sub group.
|
static |