diff options
author | omnisci3nce <omniscient.oce@gmail.com> | 2024-07-17 14:45:31 +1000 |
---|---|---|
committer | omnisci3nce <omniscient.oce@gmail.com> | 2024-07-17 14:45:31 +1000 |
commit | f8641a5cc4c8baf1f0a7be3685afc219d90143d9 (patch) | |
tree | 6f6edf43f88b456933330ec83a203bf2f414bea4 /src/core/core.c | |
parent | b9315f9cb625db09c3c41d8adf5230a67510bef7 (diff) |
whole thing is compiling and running again
Diffstat (limited to 'src/core/core.c')
-rw-r--r-- | src/core/core.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/core/core.c b/src/core/core.c index 6ccd0d0..de67b56 100644 --- a/src/core/core.c +++ b/src/core/core.c @@ -22,6 +22,8 @@ inline Core* GetCore() { return &g_core; } void Core_Bringup() { INFO("Initiate Core bringup"); + memset(&g_core, 0, sizeof(Core)); + RendererConfig conf = { .window_name = { "Celeritas Engine Core" }, .scr_width = SCR_WIDTH, .scr_height = SCR_HEIGHT, @@ -29,7 +31,7 @@ void Core_Bringup() { g_core.renderer = malloc(Renderer_GetMemReqs()); // initialise all subsystems - if (!Renderer_Init(conf, g_core.renderer)) { + if (!Renderer_Init(conf, g_core.renderer, &g_core.window)) { // FATAL("Failed to start renderer"); ERROR_EXIT("Failed to start renderer\n"); } @@ -50,8 +52,6 @@ void Core_Bringup() { // scene_init(&g_core.default_scene); } -#include <glfw3.h> - void Core_Shutdown() { Input_Shutdown(&g_core.input); Renderer_Shutdown(g_core.renderer); @@ -63,7 +63,7 @@ bool ShouldExit() { } void Frame_Begin() { - glfwPollEvents(); + Input_Update(&g_core.input); Render_FrameBegin(g_core.renderer); } void Frame_Draw() {} |