From 1d3a23e0515c971f03c72e679db1201d5f4ddc74 Mon Sep 17 00:00:00 2001 From: Alexander Olofsson Date: Sun, 16 Dec 2018 10:01:19 +0100 Subject: [PATCH] Store the initial window size in the state Fixes #107 --- client/main.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/client/main.c b/client/main.c index 104194a7..028bd6c1 100644 --- a/client/main.c +++ b/client/main.c @@ -862,6 +862,9 @@ int run() if (!params.center) SDL_SetWindowPosition(state.window, params.x, params.y); + // ensure the initial window size is stored in the state + SDL_GetWindowSize(state.window, &state.windowW, &state.windowH); + // set the compositor hint to bypass for low latency SDL_SysWMinfo wminfo; SDL_VERSION(&wminfo.version);