group2 0.1.0
CSE 125 Group 2
Loading...
Searching...
No Matches
physics::inertia Namespace Reference

Functions

glm::mat3 boxInvInertia (float mass, glm::vec3 halfExtents) noexcept
 Local-space inverse inertia tensor of a solid box of mass m and full extents (= 2 * halfExtents).
glm::mat3 sphereInvInertia (float mass, float radius) noexcept
 Local-space inverse inertia tensor of a solid sphere of mass m and radius r.
glm::mat3 capsuleInvInertia (float mass, float radius, float halfHeight) noexcept
 Local-space inverse inertia tensor of a capsule (cylinder + 2 hemispherical caps) with vertical axis (+Y), cylinder half-height h and radius r, total mass m.

Function Documentation

◆ boxInvInertia()

glm::mat3 physics::inertia::boxInvInertia ( float mass,
glm::vec3 halfExtents )
inlinenodiscardnoexcept

Local-space inverse inertia tensor of a solid box of mass m and full extents (= 2 * halfExtents).

◆ capsuleInvInertia()

glm::mat3 physics::inertia::capsuleInvInertia ( float mass,
float radius,
float halfHeight )
inlinenodiscardnoexcept

Local-space inverse inertia tensor of a capsule (cylinder + 2 hemispherical caps) with vertical axis (+Y), cylinder half-height h and radius r, total mass m.

◆ sphereInvInertia()

glm::mat3 physics::inertia::sphereInvInertia ( float mass,
float radius )
inlinenodiscardnoexcept

Local-space inverse inertia tensor of a solid sphere of mass m and radius r.