- implemented better aspect ratio control for fullscreen images.

Due to backwards compatibility needs and for flexibility this needs to be controlled by a gameinfo setting (fullscreenautoaspect):

0: Treat all images as having an aspect ratio of 4:3, this is the default for compatibility reasons
1: Scale all images to fit the screen, i.e. either pillarbox or letterbox them.
2: Scale all images to fill the screen.
3: Scale all images so that the center 4:3 area is always fully visible. This is the recommended mode for 16:9 images designed to be shown with the sides being cropped on narrower displays.

A new DTA_ tag - DTA_FullscreenEx also exists which allows specifying the scale mode directly
This commit is contained in:
Christoph Oelckers 2020-03-15 09:27:02 +01:00
commit db5efddf12
5 changed files with 64 additions and 76 deletions

View file

@ -116,6 +116,7 @@ const char* GameInfoBorders[] =
NULL
};
#define GAMEINFOKEY_CSTRING(key, variable, length) \
else if(nextKey.CompareNoCase(variable) == 0) \
{ \
@ -382,6 +383,7 @@ void FMapInfoParser::ParseGameInfo()
GAMEINFOKEY_DOUBLE(telefogheight, "telefogheight")
GAMEINFOKEY_DOUBLE(gibfactor, "gibfactor")
GAMEINFOKEY_INT(defKickback, "defKickback")
GAMEINFOKEY_INT(fullscreenautoaspect, "fullscreenautoaspect")
GAMEINFOKEY_STRING(SkyFlatName, "SkyFlatName")
GAMEINFOKEY_STRING(translator, "translator")
GAMEINFOKEY_COLOR(pickupcolor, "pickupcolor")