diff -r 60014484121c -r 67d7b79997df src/window.c --- a/src/window.c Wed Aug 06 00:37:01 2025 +0200 +++ b/src/window.c Thu Aug 07 22:40:41 2025 +0200 @@ -34,18 +34,7 @@ #include #include -void asc_window_settings_init_defaults(AscWindowSettings *settings) { - settings->dimensions.width = 800u; - settings->dimensions.height = 600u; - settings->fullscreen = false; - settings->glsettings.depth_size = 24; - settings->glsettings.vsync = 1; - settings->glsettings.gl_major_version = 4; - settings->glsettings.gl_minor_version = 0; - settings->title = "Ascended Window"; -} - -void asc_window_initialize(unsigned int index, const AscWindowSettings *settings) { +void asc_window_initialize(unsigned int index, AscGLContextSettings settings) { if (index >= ASC_MAX_WINDOWS) { asc_error("Maximum number of windows exceeded (%u/%u).", index, ASC_MAX_WINDOWS); return; @@ -57,14 +46,8 @@ } SDL_WindowFlags flags = SDL_WINDOW_OPENGL; - flags |= settings->fullscreen ? SDL_WINDOW_FULLSCREEN : SDL_WINDOW_RESIZABLE; - - window->window = SDL_CreateWindow( - settings->title, - (int) settings->dimensions.width, - (int) settings->dimensions.height, - flags - ); + flags |= settings.fullscreen ? SDL_WINDOW_FULLSCREEN : SDL_WINDOW_RESIZABLE; + window->window = SDL_CreateWindow("Ascension",800, 600, flags); if (window->window == NULL) { asc_error("Creating Window failed: %s", SDL_GetError()); return; @@ -81,7 +64,7 @@ // default UI scale window->ui_scale = 1.0f; - if (asc_gl_context_initialize(&window->glctx, window->window, &settings->glsettings)) { + if (asc_gl_context_initialize(&window->glctx, window->window, &settings)) { char ui_scene_name[16]; snprintf(ui_scene_name, sizeof(ui_scene_name), "Window %u UI", index); asc_scene_init(&window->ui, ui_scene_name,