From cc621ba0995f659c32dee4b7d7870902ef50c9eb Mon Sep 17 00:00:00 2001 From: Sergeanur Date: Sat, 5 Oct 2019 16:04:27 +0300 Subject: Corona widescreen fix --- src/core/common.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/core') diff --git a/src/core/common.h b/src/core/common.h index b3a271c6..caa305d6 100644 --- a/src/core/common.h +++ b/src/core/common.h @@ -92,9 +92,11 @@ extern void **rwengine; #define SCREEN_SCALE_FROM_BOTTOM(a) (SCREEN_HEIGHT - SCREEN_SCALE_Y(a)) #ifdef ASPECT_RATIO_SCALE -#define SCREEN_SCALE_AR(a) ((a) * (4.0f / 3.0f) / SCREEN_ASPECT_RATIO) +#define SCREEN_SCALE_AR(a) ((a) * DEFAULT_ASPECT_RATIO / SCREEN_ASPECT_RATIO) +#define SCREEN_SCALE_AR2(a) ((a) / (DEFAULT_ASPECT_RATIO / SCREEN_ASPECT_RATIO)) #else #define SCREEN_SCALE_AR(a) (a) +#define SCREEN_SCALE_AR2(a) (a) #endif #include "maths.h" -- cgit v1.2.3