Default collider using mesh bounds.
More...
#include <DefaultCollider.hpp>
|
| | DefaultCollider ()=default |
| | Default constructor (1x1x1 box).
|
| | DefaultCollider (const glm::vec3 &extents) |
| | Construct with half-extents.
|
| | DefaultCollider (const glm::vec3 &extents, const glm::vec3 &localOffset) |
| | Construct with half-extents and offset.
|
| glm::vec3 | GetSize () const |
| | Get full dimensions of the box.
|
|
| glm::vec3 | halfExtents {0.5f, 0.5f, 0.5f} |
| | Half-extents of the box (size / 2).
|
| glm::vec3 | offset {0.0f, 0.0f, 0.0f} |
| | Local offset from entity transform.
|
Default collider using mesh bounds.
This collider is automatically created if:
The box dimensions are calculated from the mesh bounds.
- Note
- Auto-managed by RigidBodySystem
◆ DefaultCollider() [1/3]
| Physics::Component::DefaultCollider::DefaultCollider |
( |
| ) |
|
|
default |
Default constructor (1x1x1 box).
◆ DefaultCollider() [2/3]
| Physics::Component::DefaultCollider::DefaultCollider |
( |
const glm::vec3 & | extents | ) |
|
|
inlineexplicit |
Construct with half-extents.
- Parameters
-
| extents | Half the size in each dimension |
◆ DefaultCollider() [3/3]
| Physics::Component::DefaultCollider::DefaultCollider |
( |
const glm::vec3 & | extents, |
|
|
const glm::vec3 & | localOffset ) |
|
inline |
Construct with half-extents and offset.
- Parameters
-
| extents | Half the size in each dimension |
| localOffset | Local position offset |
◆ GetSize()
| glm::vec3 Physics::Component::DefaultCollider::GetSize |
( |
| ) |
const |
|
inlinenodiscard |
Get full dimensions of the box.
◆ halfExtents
| glm::vec3 Physics::Component::DefaultCollider::halfExtents {0.5f, 0.5f, 0.5f} |
Half-extents of the box (size / 2).
◆ offset
| glm::vec3 Physics::Component::DefaultCollider::offset {0.0f, 0.0f, 0.0f} |
Local offset from entity transform.
The documentation for this struct was generated from the following file: