ODBETA: use 320x240 sdl surface when not hw scaling on 320x480 LCDs

This commit is contained in:
sydarn 2023-11-21 22:00:40 +01:00 committed by irixxxx
parent c180662e07
commit 0e7c531169
2 changed files with 15 additions and 3 deletions

1
configure vendored
View file

@ -127,6 +127,7 @@ set_platform()
odbeta)
# various devices with opendingux beta, arch flags from toolchain default
MFLAGS=""
CFLAGS="$CFLAGS -D__ODBETA__"
platform="opendingux"
;;
pandora)

View file

@ -331,8 +331,19 @@ static void plat_sdl_resize(int w, int h)
{
// take over new settings
if (plat_sdl_screen->w != area.w || plat_sdl_screen->h != area.h) {
#if defined(__ODBETA__)
if (currentConfig.vscaling != EOPT_SCALE_HW &&
plat_sdl_screen->w == 320 &&
plat_sdl_screen->h == 480) {
g_menuscreen_h = 240;
g_menuscreen_w = 320;
} else
#endif
{
g_menuscreen_h = plat_sdl_screen->h;
g_menuscreen_w = plat_sdl_screen->w;
}
resize_buffers();
rendstatus_old = -1;
}