Lock compositor to 1920x1080

This commit is contained in:
NeilClack
2026-08-17 22:46:44 -05:00
parent 74245ee07d
commit ec6b76618c
+8
View File
@@ -57,6 +57,14 @@ SDL_AppResult SDL_AppInit(void **appstate, int argc, char *argv[])
"VSync could not be enabled; scrolling text may tear (VSync error: " + std::string(SDL_GetError()) + ")");
}
// Lock the renderer to a 1920x1080 logical coordinate space. All page
// layout code already targets this resolution, so everything renders at
// the correct size on any display — the GPU scales to native pixels.
if (!SDL_SetRenderLogicalPresentation(state->renderer, 1920, 1080, SDL_LOGICAL_PRESENTATION_STRETCH)) {
radiantwave::logger::Logger::instance().warning("Graphics",
"Could not set logical render size; layout may be wrong on HiDPI displays");
}
SDL_HideCursor();
// Initialize configuration, database, and network manager