SDL: Prevent resizing below 1x resolution with integer scaling
Anty-Lemon Anty-Lemon@users.noreply.github.com
Sat, 06 May 2017 19:41:07 -0400
1 files changed,
3 insertions(+),
0 deletions(-)
jump to
M
src/platform/sdl/gl-common.c
→
src/platform/sdl/gl-common.c
@@ -38,6 +38,9 @@ renderer->glCtx = SDL_GL_CreateContext(renderer->window);
SDL_GL_SetSwapInterval(1); SDL_GetWindowSize(renderer->window, &renderer->viewportWidth, &renderer->viewportHeight); renderer->player.window = renderer->window; + if (renderer->lockIntegerScaling) { + SDL_SetWindowMinimumSize(renderer->window, renderer->width, renderer->height); + } #else SDL_GL_SetAttribute(SDL_GL_SWAP_CONTROL, 1); #ifdef COLOR_16_BIT