From 6e4540372bb862afb4fc084d5c5e68ba0ae9c67a Mon Sep 17 00:00:00 2001 From: realtradam Date: Tue, 3 Jan 2023 17:42:06 -0500 Subject: convert to library --- include/rodeo.h | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 include/rodeo.h (limited to 'include') diff --git a/include/rodeo.h b/include/rodeo.h new file mode 100644 index 0000000..e468c11 --- /dev/null +++ b/include/rodeo.h @@ -0,0 +1,42 @@ +#include +#include "SDL2/SDL.h" +#include "SDL2/SDL_syswm.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; + +void +Rodeo__\ +init_window( + Rodeo__Data_t* state, + int screen_height, + int screen_width, + char* title + ); + +void +Rodeo__\ +deinit_window(Rodeo__Data_t* state); + +void +Rodeo__\ +quit(); + +void +Rodeo__\ +begin(Rodeo__Data_t* state); + +void +Rodeo__\ +end(Rodeo__Data_t* state); -- cgit v1.2.3