From 18efb35602e2e9e6348b26dc6f722000ce31d0a9 Mon Sep 17 00:00:00 2001 From: "James R." Date: Sat, 30 Sep 2023 16:07:53 -0700 Subject: [PATCH] SDLSetMode: render immediately after resolution change to avoid 1-frame of texture presented at wrong size --- src/sdl/i_video.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/sdl/i_video.cpp b/src/sdl/i_video.cpp index 84af0eed8..bd47a09c6 100644 --- a/src/sdl/i_video.cpp +++ b/src/sdl/i_video.cpp @@ -235,6 +235,11 @@ static void SDLSetMode(INT32 width, INT32 height, SDL_bool fullscreen, SDL_bool SDL_GetWindowSize(window, &width, &height); vid.realwidth = static_cast(width); vid.realheight = static_cast(height); + + if (graphics_started) + { + I_UpdateNoVsync(); + } } static INT32 Impl_SDL_Scancode_To_Keycode(SDL_Scancode code)