Tramway SDK
Static Public Member Functions | Public Attributes | List of all members
tram::Physics::CollisionShape Struct Reference

#include <collisionshape.h>

Static Public Member Functions

static CollisionShape Sphere (float radius)
 
static CollisionShape Cylinder (float radius, float height)
 
static CollisionShape Capsule (float radius, float height)
 
static CollisionShape Cone (float radius, float height)
 
static CollisionShape Box (vec3 dimensions)
 
static CollisionShape Hull (vec3 *points, size_t size)
 
static CollisionShape Mesh (CollisionTriangle *triangles, size_t size)
 

Public Attributes

Shape type
 
union {
   struct {
      union {
         float   radius
 
         float   radius_x
 
         float   extent_x
 
      } 
 
      union {
         float   height
 
         float   extent_y
 
      } 
 
      union {
         float   extent_z
 
         float   radius_z
 
      } 
 
   } 
 
   struct {
      vec3 *   hull_points
 
      size_t   hull_size
 
   } 
 
   struct {
      CollisionTriangle *   mesh_triangles
 
      size_t   mesh_size
 
   } 
 
}; 
 

Member Function Documentation

◆ Box()

CollisionShape tram::Physics::CollisionShape::Box ( vec3  dimensions)
inlinestatic

◆ Capsule()

CollisionShape tram::Physics::CollisionShape::Capsule ( float  radius,
float  height 
)
inlinestatic

◆ Cone()

CollisionShape tram::Physics::CollisionShape::Cone ( float  radius,
float  height 
)
inlinestatic

◆ Cylinder()

CollisionShape tram::Physics::CollisionShape::Cylinder ( float  radius,
float  height 
)
inlinestatic

◆ Hull()

CollisionShape tram::Physics::CollisionShape::Hull ( vec3 points,
size_t  size 
)
inlinestatic

◆ Mesh()

CollisionShape tram::Physics::CollisionShape::Mesh ( CollisionTriangle triangles,
size_t  size 
)
inlinestatic

◆ Sphere()

CollisionShape tram::Physics::CollisionShape::Sphere ( float  radius)
inlinestatic

Member Data Documentation

◆ 

union { ... } tram::Physics::CollisionShape::@34

◆ extent_x

float tram::Physics::CollisionShape::extent_x

◆ extent_y

float tram::Physics::CollisionShape::extent_y

◆ extent_z

float tram::Physics::CollisionShape::extent_z

◆ height

float tram::Physics::CollisionShape::height

◆ hull_points

vec3* tram::Physics::CollisionShape::hull_points

◆ hull_size

size_t tram::Physics::CollisionShape::hull_size

◆ mesh_size

size_t tram::Physics::CollisionShape::mesh_size

◆ mesh_triangles

CollisionTriangle* tram::Physics::CollisionShape::mesh_triangles

◆ radius

float tram::Physics::CollisionShape::radius

◆ radius_x

float tram::Physics::CollisionShape::radius_x

◆ radius_z

float tram::Physics::CollisionShape::radius_z

◆ type

Shape tram::Physics::CollisionShape::type

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