RavEngine
Loading...
Searching...
No Matches
RavEngine::CapsuleCollider Class Reference
Inheritance diagram for RavEngine::CapsuleCollider:
[legend]
Collaboration diagram for RavEngine::CapsuleCollider:
[legend]

Public Member Functions

 CapsuleCollider (PhysicsBodyComponent *owner, decimalType r, decimalType hh, Ref< PhysicsMaterial > mat, const vector3 &position=vector3(0, 0, 0), const quaternion &rotation=quaternion(1.0, 0.0, 0.0, 0.0))
 
void DebugDraw (RavEngine::DebugDrawer &dbg, color_t, const RavEngine::Transform &) const override
 
- Public Member Functions inherited from RavEngine::PhysicsCollider
void UpdateFilterData (PhysicsBodyComponent *owner)
 
void SetType (CollisionType)
 
CollisionType GetType () const
 
void SetQueryable (bool)
 
bool GetQueryable () const
 
void SetRelativeTransform (const vector3 &position, const quaternion &rotation)
 
Transformation GetRelativeTransform () const
 

Protected Attributes

decimalType radius
 
decimalType halfHeight
 
- Protected Attributes inherited from RavEngine::PhysicsCollider
physx::PxShape * collider = nullptr
 
Ref< PhysicsMaterial > material
 

Additional Inherited Members

- Public Types inherited from RavEngine::PhysicsCollider
enum class  CollisionType { Trigger , Collider }
 
- Protected Member Functions inherited from RavEngine::PhysicsCollider
matrix4 CalculateWorldMatrix (const RavEngine::Transform &) const
 

Constructor & Destructor Documentation

◆ CapsuleCollider()

CapsuleCollider::CapsuleCollider ( PhysicsBodyComponent *  owner,
decimalType  r,
decimalType  hh,
Ref< PhysicsMaterial >  mat,
const vector3 &  position = vector3(0,0,0),
const quaternion &  rotation = quaternion(1.0, 0.0, 0.0, 0.0) 
)

Create a capsule collider with a material

Parameters
rradius of the collider
hthe half-height of the collider
matthe physics material of the shape
positionthe relative position of the shape
rotationthe relative rotation of the shape

Member Function Documentation

◆ DebugDraw()

void CapsuleCollider::DebugDraw ( RavEngine::DebugDrawer &  dbg,
color_t  debug_color,
const RavEngine::Transform &  tr 
) const
overridevirtual

Draw a wireframe shape representing the boundary of this collider

Parameters
colorthe hex color to use to draw, in format 0xRRGGBBAA

Reimplemented from RavEngine::PhysicsCollider.


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