From 8744a70dcfbc4219a1b85bf356dabdf493b7fa54 Mon Sep 17 00:00:00 2001 From: hendricks266 Date: Fri, 26 Jan 2018 04:35:19 +0000 Subject: [PATCH] Fix the aspect of save thumbnails in Polymost / Polymer in widescreen. Patch from Fox. git-svn-id: https://svn.eduke32.com/eduke32@6593 1a8010ca-5511-0410-912e-c29ae57300e0 --- source/duke3d/src/game.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/duke3d/src/game.cpp b/source/duke3d/src/game.cpp index 7ce057703..e59e148c8 100644 --- a/source/duke3d/src/game.cpp +++ b/source/duke3d/src/game.cpp @@ -660,7 +660,7 @@ static void G_ReadGLFrame(void) char *const pic = (char *) waloff[TILE_SAVESHOT]; int32_t x, y; - const int32_t xf = divscale16(xdim, 320); // (xdim<<16)/320 + const int32_t xf = divscale16(ydim*4/3, 320); const int32_t yf = divscale16(ydim, 200); // (ydim<<16)/200 tilesiz[TILE_SAVESHOT].x = 200; @@ -682,7 +682,7 @@ static void G_ReadGLFrame(void) for (x = 0; x < 320; x++) { - const palette_t *pix = &frame[base + mulscale16(x, xf)]; + const palette_t *pix = &frame[base + mulscale16(x, xf) + (xdim-(ydim*4/3))/2]; pic[320 * y + x] = getclosestcol(pix->r, pix->g, pix->b); } }