From f3546f948a66aa505aee770879fc125e855afec8 Mon Sep 17 00:00:00 2001 From: Curtis McEnroe Date: Sun, 24 Mar 2019 16:21:43 -0400 Subject: Use SDL_RenderSetLogicalSize rather than SetScale --- sol.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/sol.c b/sol.c index c0882ac..930eda6 100644 --- a/sol.c +++ b/sol.c @@ -431,19 +431,10 @@ int main(void) { &window, &render ); if (error) err("SDL_CreateWindowAndRenderer"); - SDL_SetWindowTitle(window, "Solitaire"); - int width, height; - SDL_GetRendererOutputSize(render, &width, &height); - if (width > WindowWidth && height > WindowHeight) { - SDL_RenderSetIntegerScale(render, SDL_TRUE); - SDL_RenderSetScale( - render, - (float)width / WindowWidth, - (float)height / WindowHeight - ); - } + SDL_RenderSetIntegerScale(render, SDL_TRUE); + SDL_RenderSetLogicalSize(render, WindowWidth, WindowHeight); for (uint i = 0; i < Cards_Count; ++i) { textures[i] = NULL; -- cgit 1.4.1