summaryrefslogtreecommitdiff
path: root/src/core/include/engine/engine.h
diff options
context:
space:
mode:
author0scar <qgt268@alumni.ku.dk>2024-02-06 22:58:28 +0000
committer0scar <qgt268@alumni.ku.dk>2024-02-06 22:59:38 +0000
commit5f42765139ae678ad3f210a4a08c4c462ccb8853 (patch)
tree07df80dff8cdcd130d5a61bc3001d70638c1b533 /src/core/include/engine/engine.h
parentb1d13c646301bb04f16a2fecaa06511567d01e1f (diff)
General cleanup
Diffstat (limited to 'src/core/include/engine/engine.h')
-rw-r--r--src/core/include/engine/engine.h58
1 files changed, 5 insertions, 53 deletions
diff --git a/src/core/include/engine/engine.h b/src/core/include/engine/engine.h
index 1715f8a..ec685f5 100644
--- a/src/core/include/engine/engine.h
+++ b/src/core/include/engine/engine.h
@@ -3,8 +3,9 @@
#include <stdbool.h>
-// TODO: Cleanup the includes, ideally this header file should only include all
-// "public-facing" headers.
+/* TODO: Cleanup the includes, ideally this header file should only include all
+ * "public-facing" headers.
+ */
#include <engine/core/types.h>
#include <engine/core/logging.h>
@@ -21,44 +22,7 @@ typedef struct {
} RenderUnit;
#include <engine/rendering/window.h>
-
-#define NUM_GLOBAL_BINDINGS 1
-typedef struct {
- void* data; /* Contains textures and such */
- u64 data_len;
-
- Window window;
- bool quit;
-
- u64 frame;
- f32 fps_target;
-
- /* TODO: Move mouse data to input ctx */
- v2_i32 mouse_pos;
-
- v2_i32 mousedown;
- v2_i32 mouseup;
-
- bool mouse_lclick;
- bool mouse_rclick;
-
- i32 camera_x;
- i32 camera_y;
-
- /* Text input/editing is currently not used/implemented */
- char* edit_text;
- usize edit_pos;
-
- memory* mem;
-
- i_ctx** bindings;
- usize bindings_sz;
- usize bindings_len;
-
- struct RenderObject *testobject;
-
- binding_t bindings_global[NUM_GLOBAL_BINDINGS];
-} Platform;
+#include <engine/core/platform.h>
/* Essential functions */
Platform* engine_init(const char* windowtitle, i32 windowWidth, i32 windowHeight,
@@ -77,23 +41,11 @@ void render_set_zoom(f32 new_zoom);
void render_adjust_zoom(f32 diff);
void render_add_unit(RenderUnit* u);
-f64 get_time(void);
-//v2_i32 get_windowsize(void);
-v2_i32* get_mousepos(void);
/* Input handling */
void engine_input_ctx_push(i_ctx* ctx);
void engine_input_ctx_pop(void);
void engine_input_ctx_reset(void);
+v2_i32* get_mousepos(void);
-//#include <engine/rendering/rendering.h>
-
-//#ifdef ENGINE_INTERNALS
-//
-//#include <glad/gl.h>
-//#define GLFW_INCLUDE_NONE
-//#include <GLFW/glfw3.h>
-//
-//
-//#endif
#endif