Jolt Physics
A multi core friendly Game Physics Engine
Loading...
Searching...
No Matches
PhysicsUpdateContext::Step::CCDBody Struct Reference

Contains the information needed to cast a body through the scene to do continuous collision detection. More...

#include <PhysicsUpdateContext.h>

Public Member Functions

 CCDBody (BodyID inBodyID1, Vec3Arg inDeltaPosition, float inLinearCastThresholdSq, float inMaxPenetration)
 

Public Attributes

Vec3 mDeltaPosition
 Desired rotation step.
 
Vec3 mContactNormal
 World space normal of closest hit (only valid if mFractionPlusSlop < 1)
 
RVec3 mContactPointOn2
 World space contact point on body 2 of closest hit (only valid if mFractionPlusSlop < 1)
 
BodyID mBodyID1
 Body 1 (the body that is performing collision detection)
 
BodyID mBodyID2
 Body 2 (the body of the closest hit, only valid if mFractionPlusSlop < 1)
 
SubShapeID mSubShapeID2
 Sub shape of body 2 that was hit (only valid if mFractionPlusSlop < 1)
 
float mFraction = 1.0f
 Fraction at which the hit occurred.
 
float mFractionPlusSlop = 1.0f
 Fraction at which the hit occurred + extra delta to allow body to penetrate by mMaxPenetration.
 
float mLinearCastThresholdSq
 Maximum allowed squared movement before doing a linear cast (determined by inner radius of shape)
 
float mMaxPenetration
 Maximum allowed penetration (determined by inner radius of shape)
 
ContactSettings mContactSettings
 The contact settings for this contact.
 

Detailed Description

Contains the information needed to cast a body through the scene to do continuous collision detection.

Constructor & Destructor Documentation

◆ CCDBody()

PhysicsUpdateContext::Step::CCDBody::CCDBody ( BodyID  inBodyID1,
Vec3Arg  inDeltaPosition,
float  inLinearCastThresholdSq,
float  inMaxPenetration 
)
inline

Member Data Documentation

◆ mBodyID1

BodyID PhysicsUpdateContext::Step::CCDBody::mBodyID1

Body 1 (the body that is performing collision detection)

◆ mBodyID2

BodyID PhysicsUpdateContext::Step::CCDBody::mBodyID2

Body 2 (the body of the closest hit, only valid if mFractionPlusSlop < 1)

◆ mContactNormal

Vec3 PhysicsUpdateContext::Step::CCDBody::mContactNormal

World space normal of closest hit (only valid if mFractionPlusSlop < 1)

◆ mContactPointOn2

RVec3 PhysicsUpdateContext::Step::CCDBody::mContactPointOn2

World space contact point on body 2 of closest hit (only valid if mFractionPlusSlop < 1)

◆ mContactSettings

ContactSettings PhysicsUpdateContext::Step::CCDBody::mContactSettings

The contact settings for this contact.

◆ mDeltaPosition

Vec3 PhysicsUpdateContext::Step::CCDBody::mDeltaPosition

Desired rotation step.

◆ mFraction

float PhysicsUpdateContext::Step::CCDBody::mFraction = 1.0f

Fraction at which the hit occurred.

◆ mFractionPlusSlop

float PhysicsUpdateContext::Step::CCDBody::mFractionPlusSlop = 1.0f

Fraction at which the hit occurred + extra delta to allow body to penetrate by mMaxPenetration.

◆ mLinearCastThresholdSq

float PhysicsUpdateContext::Step::CCDBody::mLinearCastThresholdSq

Maximum allowed squared movement before doing a linear cast (determined by inner radius of shape)

◆ mMaxPenetration

float PhysicsUpdateContext::Step::CCDBody::mMaxPenetration

Maximum allowed penetration (determined by inner radius of shape)

◆ mSubShapeID2

SubShapeID PhysicsUpdateContext::Step::CCDBody::mSubShapeID2

Sub shape of body 2 that was hit (only valid if mFractionPlusSlop < 1)


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