This file contains global type definitions which are used throughout the entire engine and applicatio...
#define KAPI
Import/export qualifier.
Definition: defines.h:177
unsigned int u32
Unsigned 32-bit integer.
Definition: defines.h:25
_Bool b8
8-bit boolean type
Definition: defines.h:58
float f32
32-bit floating point number
Definition: defines.h:47
Contains various math types required for the engine.
This file contains the types for common resources the engine uses.
#define TERRAIN_MAX_MATERIAL_COUNT
Definition: resource_types.h:16
Represents the extents of a 3d object.
Definition: math_types.h:165
Represents actual geometry in the world. Typically (but not always, depending on use) paired with a m...
Definition: resource_types.h:311
u32 material_count
Definition: terrain.h:54
transform xform
Definition: terrain.h:49
char * name
Definition: terrain.h:39
u32 vertex_data_length
Definition: terrain.h:51
f32 scale_y
Definition: terrain.h:47
f32 tile_scale_x
Definition: terrain.h:43
char ** material_names
Definition: terrain.h:55
f32 tile_scale_z
Definition: terrain.h:45
u32 tile_count_z
Definition: terrain.h:41
u32 tile_count_x
Definition: terrain.h:40
terrain_vertex_data * vertex_datas
Definition: terrain.h:52
f32 height
Definition: terrain.h:35
vec3 position
The position of the vertex.
Definition: terrain.h:20
vec3 normal
The normal of the vertex.
Definition: terrain.h:22
vec2 texcoord
The texture coordinate of the vertex.
Definition: terrain.h:24
vec4 tangent
The tangent of the vertex.
Definition: terrain.h:28
f32 material_weights[TERRAIN_MAX_MATERIAL_COUNT]
A collection of material weights for this vertex.
Definition: terrain.h:31
vec4 colour
The colour of the vertex.
Definition: terrain.h:26
u32 material_count
Definition: terrain.h:85
transform xform
Definition: terrain.h:61
u32 * indices
Definition: terrain.h:81
geometry geo
Definition: terrain.h:83
u32 unique_id
Definition: terrain.h:59
u32 index_count
Definition: terrain.h:80
char * name
Definition: terrain.h:60
vec3 origin
Definition: terrain.h:75
u32 vertex_data_length
Definition: terrain.h:71
f32 scale_y
Definition: terrain.h:69
terrain_vertex * vertices
Definition: terrain.h:78
u32 vertex_count
Definition: terrain.h:77
f32 tile_scale_x
Definition: terrain.h:65
char ** material_names
Definition: terrain.h:86
f32 tile_scale_z
Definition: terrain.h:67
u32 tile_count_z
Definition: terrain.h:63
u32 tile_count_x
Definition: terrain.h:62
extents_3d extents
Definition: terrain.h:74
terrain_vertex_data * vertex_datas
Definition: terrain.h:72
KAPI b8 terrain_update(terrain *t)
KAPI void terrain_destroy(terrain *t)
struct terrain_vertex terrain_vertex
KAPI b8 terrain_unload(terrain *t)
KAPI b8 terrain_load(terrain *t)
KAPI b8 terrain_create(const terrain_config *config, terrain *out_terrain)
struct terrain_vertex_data terrain_vertex_data
KAPI b8 terrain_initialize(terrain *t)
struct terrain_config terrain_config
A 2-element vector.
Definition: math_types.h:19
A 3-element vector.
Definition: math_types.h:49
A 4-element vector.
Definition: math_types.h:89