Jolt Physics
A multi core friendly Game Physics Engine
Loading...
Searching...
No Matches
ShapeCastSettings Class Reference

Settings to be passed with a shape cast. More...

#include <ShapeCast.h>

Inheritance diagram for ShapeCastSettings:
CollideSettingsBase

Public Attributes

JPH_OVERRIDE_NEW_DELETE EBackFaceMode mBackFaceModeTriangles = EBackFaceMode::IgnoreBackFaces
 How backfacing triangles should be treated (should we report moving out of a triangle?) More...
 
EBackFaceMode mBackFaceModeConvex = EBackFaceMode::IgnoreBackFaces
 How backfacing convex objects should be treated (should we report starting inside an object and moving out?) More...
 
bool mUseShrunkenShapeAndConvexRadius = false
 Indicates if we want to shrink the shape by the convex radius and then expand it again. This speeds up collision detection and gives a more accurate normal at the cost of a more 'rounded' shape. More...
 
bool mReturnDeepestPoint = false
 When true, and the shape is intersecting at the beginning of the cast (fraction = 0) then this will calculate the deepest penetration point (costing additional CPU time) More...
 
- Public Attributes inherited from CollideSettingsBase
JPH_OVERRIDE_NEW_DELETE EActiveEdgeMode mActiveEdgeMode = EActiveEdgeMode::CollideOnlyWithActive
 How active edges (edges that a moving object should bump into) are handled. More...
 
ECollectFacesMode mCollectFacesMode = ECollectFacesMode::NoFaces
 If colliding faces should be collected or only the collision point. More...
 
float mCollisionTolerance = cDefaultCollisionTolerance
 If objects are closer than this distance, they are considered to be colliding (used for GJK) (unit: meter) More...
 
float mPenetrationTolerance = cDefaultPenetrationTolerance
 A factor that determines the accuracy of the penetration depth calculation. If the change of the squared distance is less than tolerance * current_penetration_depth^2 the algorithm will terminate. (unit: dimensionless) More...
 
Vec3 mActiveEdgeMovementDirection = Vec3::sZero()
 When mActiveEdgeMode is CollideOnlyWithActive a movement direction can be provided. When hitting an inactive edge, the system will select the triangle normal as penetration depth only if it impedes the movement less than with the calculated penetration depth. More...
 

Detailed Description

Settings to be passed with a shape cast.

Member Data Documentation

◆ mBackFaceModeConvex

EBackFaceMode ShapeCastSettings::mBackFaceModeConvex = EBackFaceMode::IgnoreBackFaces

How backfacing convex objects should be treated (should we report starting inside an object and moving out?)

◆ mBackFaceModeTriangles

JPH_OVERRIDE_NEW_DELETE EBackFaceMode ShapeCastSettings::mBackFaceModeTriangles = EBackFaceMode::IgnoreBackFaces

How backfacing triangles should be treated (should we report moving out of a triangle?)

◆ mReturnDeepestPoint

bool ShapeCastSettings::mReturnDeepestPoint = false

When true, and the shape is intersecting at the beginning of the cast (fraction = 0) then this will calculate the deepest penetration point (costing additional CPU time)

◆ mUseShrunkenShapeAndConvexRadius

bool ShapeCastSettings::mUseShrunkenShapeAndConvexRadius = false

Indicates if we want to shrink the shape by the convex radius and then expand it again. This speeds up collision detection and gives a more accurate normal at the cost of a more 'rounded' shape.


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