diff options
Diffstat (limited to 'assets/src')
| -rw-r--r-- | assets/src/gunner.h | 31 |
1 files changed, 20 insertions, 11 deletions
diff --git a/assets/src/gunner.h b/assets/src/gunner.h index cbcbe87..51ebc1a 100644 --- a/assets/src/gunner.h +++ b/assets/src/gunner.h @@ -1,6 +1,6 @@ #pragma once -// Defines +// Defines // typedef struct{ unsigned char r; @@ -9,38 +9,47 @@ typedef struct{ unsigned char a; }Color; +#define WHITE (Color){255, 255, 255, 255} #define BLACK (Color){0, 0, 0, 255} -// Texture +typedef int i32; +typedef long long i64; -void init_tex_sys(void); +typedef unsigned int u32; +typedef unsigned long long u64; + +typedef float f32; +typedef double f64; + +// 24.8 format +typedef i32 fx32; +#define FIXED_POINT_BITS 8 +#define FIXED_POINT_ONE (1 << FIXED_POINT_BITS) +#define TO_FIXED(x) ((fx32)(x) << FIXED_POINT_BITS) +#define FROM_FIXED(x) ((x) >> FIXED_POINT_BITS) + +// Texture // int load_new_tex(const char* path); void draw_texture(int idx, int x, int y); -void update_textures(void); - void unload_tex(int idx); void unload_active_textures(void); -// Shader - -void init_shader_sys(void); +// Shader // int load_new_shader(const char* path); void set_active_shader(int idx); -void update_shaders(void); - void reset_active_shader(void); void unload_shader(int idx); void unload_active_shaders(void); -// Text +// Text // void draw_text(const char* txt, int x, int y, int size, Color col);
\ No newline at end of file |
