From 818f818f583881156eb279c71b1359bf2c4f3580 Mon Sep 17 00:00:00 2001 From: pryazha Date: Sun, 12 Oct 2025 15:25:23 +0500 Subject: change identation, maybe will change back, add own gl functions loading, and glx example --- oldtypes.h | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 oldtypes.h (limited to 'oldtypes.h') diff --git a/oldtypes.h b/oldtypes.h new file mode 100644 index 0000000..c7f8bd1 --- /dev/null +++ b/oldtypes.h @@ -0,0 +1,50 @@ +#define BBOX_UNIT (bbox_t){{-0.5f, -0.5f, -0.5f}, {0.5f, 0.5f, 0.5f}} +#define BBOX_ZERO (bbox_t){V3_ZERO, V3_ZERO} + +typedef struct { + v3 start; + v3 end; +} bbox_t; + +#define ENTITY_COLLIDE (1) +#define ENTITY_MOVE (1 << 1) +#define ENTITY_ALPHA (1 << 2) + +typedef struct { + u32 flags; + + model_t model; + + v3 position; + v3 velocity; + bbox_t bbox; +} entity_t; + +#define MAX_ENTITIES 4 + +typedef struct enode_t { + i32 id; + entity_t entity; + struct enode_t *next; + struct enode_t *prev; +} enode_t; + +typedef struct { + i32 count; + enode_t nodes[MAX_ENTITIES]; + struct enode_t *first; + struct enode_t *last; +} elist_t; + +typedef enum {ui_list, ui_stack} ui_layout_enum; + +typedef struct { + prge_window_t window; + input_t input; + shader_t shader; + rect_t rect; + ui_layout_enum layout; + v2 last; + arena_t *arena; + f32 padding; +} ui_t; -- cgit v1.2.3-70-g09d2