Page 1 of 2

Savegame thumbnails are generated incorrectly

Posted: Wed May 30, 2018 10:07 am
by Marisa the Magician
Whenever the game is saved, the savepic.png comes out like this:
Image

This is happening even after commit a0695cb (which I thought would fix it).
Looking through my savegames, it seems the most recent one with a correct thumbnail is from 2aee68d, which is about a month old. Might take pretty long to bisect this.

Edit: It seems that thumbnails are generated correctly on software renderers. Also, the screen resolution / scaling changes the size of the little square area (the lower the resolution, the bigger the square is).

Re: Savegame thumbnails are generated incorrectly

Posted: Wed May 30, 2018 10:08 am
by wildweasel
I seem to recall someone else having this problem, ages ago - what screen resolution is GZDoom using?

Re: Savegame thumbnails are generated incorrectly

Posted: Wed May 30, 2018 10:10 am
by Marisa the Magician
I run at 1920x1080 (native res). Sometimes with 0.5x scaling if I need extra FPS.

Re: Savegame thumbnails are generated incorrectly

Posted: Wed May 30, 2018 11:12 am
by drfrag
Whatever it is it's not in my branch so it's a consequence of the refactor.

Re: Savegame thumbnails are generated incorrectly

Posted: Wed May 30, 2018 12:58 pm
by _mental_
Is it on Linux? I tested on Windows and macOS but with no scaling.

Re: Savegame thumbnails are generated incorrectly

Posted: Wed May 30, 2018 2:39 pm
by Marisa the Magician
Yes, this is on Linux.

Re: Savegame thumbnails are generated incorrectly

Posted: Thu May 31, 2018 2:59 am
by _mental_
Cannot reproduce this on Ubuntu 16.04 VM. Could you please attach your .ini file?

Re: Savegame thumbnails are generated incorrectly

Posted: Thu May 31, 2018 5:17 pm
by Marisa the Magician
https://marisakirisa.me/tmp/gzdoom.ini

(refresh if it gave you a 403, seems like the permissions got a bit screwy when I uploaded the file)

Re: Savegame thumbnails are generated incorrectly

Posted: Fri Jun 01, 2018 2:30 am
by fakemai
Thought I'd give it a go with your INI and a current Git build (2d50f535ff666a9cb0a0d3fe97c31f07e5a6f9a8) but couldn't reproduce. Am running Debian Stable, but also an ancient Intel GM45, so don't put too much faith in this. It could well be system-dependent though.

Re: Savegame thumbnails are generated incorrectly

Posted: Fri Jun 01, 2018 2:56 am
by _mental_
I managed to reproduce this on Windows. Enable tone mapping (set gl_tonemap CVAR to true) and the bug will appear.

Re: Savegame thumbnails are generated incorrectly

Posted: Sat Jun 02, 2018 4:05 am
by Graf Zahl
I cannot reproduce this with any tonemap (or other postprocessing) effect.

Re: Savegame thumbnails are generated incorrectly

Posted: Sat Jun 02, 2018 4:26 am
by _mental_
It should be enough to have gl_tonemap 1 and everything else by default.
BTW tonemap and lens distortion give even more weird picture
savepic.png
savepic.png (67.07 KiB) Viewed 458 times
Screen resolution is 1440x900, thumbnail size is 216x162 and this corresponds to black rectangle in the corner.
This seems to be introduces with this commit and it's somehow related to switching of render buffers target textures.

Re: Savegame thumbnails are generated incorrectly

Posted: Sat Jun 02, 2018 4:36 am
by Graf Zahl
I'll leave this to dpJudas then. Apparently I missed something important about the setup and I do not want to make it worse.

Re: Savegame thumbnails are generated incorrectly

Posted: Sat Jun 02, 2018 8:11 am
by dpJudas
Okay, I'll take a look soon. Based on the screen shots, it probably has something to do with glViewport not being what the screenshot code reading from the back buffer expects.

Re: Savegame thumbnails are generated incorrectly

Posted: Sat Jun 02, 2018 8:32 am
by XxMiltenXx
I also have a savegame thumbnail issue that might be related:
FXAA-Savegame.png
This happens under Windows 10 (build 10.0.16299.431) when FXAA is enabled. I used a new INI file and simply enabled FXAA (doesn't matter which quality setting)