summaryrefslogtreecommitdiffhomepage
path: root/include/rodeo.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/rodeo.h')
-rw-r--r--include/rodeo.h61
1 files changed, 33 insertions, 28 deletions
diff --git a/include/rodeo.h b/include/rodeo.h
index 86505f1..4686cb5 100644
--- a/include/rodeo.h
+++ b/include/rodeo.h
@@ -1,40 +1,23 @@
#include <stdbool.h>
+#include <stdio.h>
+#include <string.h>
+#include <limits.h>
+
#include "SDL2/SDL.h"
#include "SDL2/SDL_syswm.h"
+#include "bgfx/c99/bgfx.h"
-typedef
-struct
-Rodeo__\
-data_t
-{
- SDL_Window* window;
- SDL_Surface* screen_surface;
- SDL_SysWMinfo wmi;
- int screen_width;
- int screen_height;
- SDL_Event sdl_event;
- bool quit;
-} Rodeo__data_t;
+#include "rodeo_types.h"
-typedef
-struct
-Rodeo__\
-color_t
-{
- float red;
- float green;
- float blue;
- float alpha;
-} Rodeo__color_t;
void
Rodeo__\
init_window(
- Rodeo__data_t* state,
- int screen_height,
- int screen_width,
- char* title
- );
+ Rodeo__data_t* state,
+ int screen_height,
+ int screen_width,
+ char* title
+);
void
Rodeo__\
@@ -56,3 +39,25 @@ void
Rodeo__\
draw_debug_text(u_int16_t x, u_int16_t y, const char *format, ...);
+const char *
+Rodeo__\
+get_renderer_name_as_string();
+
+void
+Rodeo__\
+flush_batch(Rodeo__data_t *state);
+
+void
+Rodeo__\
+draw_rectangle(
+ Rodeo__data_t *state,
+ u_int16_t x,
+ u_int16_t y,
+ u_int16_t width,
+ u_int16_t height,
+ struct Rodeo__color_rgba_t color
+);
+
+bgfx_shader_handle_t
+Rodeo__\
+load_shader(const char* path);