summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2019-10-05 15:04:27 +0200
committerSergeanur <s.anureev@yandex.ua>2019-10-05 15:04:27 +0200
commitcc621ba0995f659c32dee4b7d7870902ef50c9eb (patch)
treed729af888ecaccba31c2d6522ae780321e8e64af /src
parentFix warnings (diff)
downloadre3-cc621ba0995f659c32dee4b7d7870902ef50c9eb.tar
re3-cc621ba0995f659c32dee4b7d7870902ef50c9eb.tar.gz
re3-cc621ba0995f659c32dee4b7d7870902ef50c9eb.tar.bz2
re3-cc621ba0995f659c32dee4b7d7870902ef50c9eb.tar.lz
re3-cc621ba0995f659c32dee4b7d7870902ef50c9eb.tar.xz
re3-cc621ba0995f659c32dee4b7d7870902ef50c9eb.tar.zst
re3-cc621ba0995f659c32dee4b7d7870902ef50c9eb.zip
Diffstat (limited to '')
-rw-r--r--src/core/common.h4
-rw-r--r--src/render/Coronas.cpp4
2 files changed, 5 insertions, 3 deletions
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"
diff --git a/src/render/Coronas.cpp b/src/render/Coronas.cpp
index 1a6cfea3..89a85e92 100644
--- a/src/render/Coronas.cpp
+++ b/src/render/Coronas.cpp
@@ -324,7 +324,7 @@ CCoronas::Render(void)
CSprite::RenderOneXLUSprite(spriteCoors.x, spriteCoors.y, spriteCoors.z,
spritew * aCoronas[i].size * wscale,
- spriteh * aCoronas[i].size * fogscale * hscale,
+ spriteh * SCREEN_SCALE_AR2(aCoronas[i].size * fogscale * hscale),
CCoronas::aCoronas[i].red / fogscale,
CCoronas::aCoronas[i].green / fogscale,
CCoronas::aCoronas[i].blue / fogscale,
@@ -335,7 +335,7 @@ CCoronas::Render(void)
CSprite::RenderOneXLUSprite_Rotate_Aspect(
spriteCoors.x, spriteCoors.y, spriteCoors.z,
spritew * aCoronas[i].size * fogscale,
- spriteh * aCoronas[i].size * fogscale,
+ spriteh * SCREEN_SCALE_AR2(aCoronas[i].size * fogscale),
CCoronas::aCoronas[i].red / fogscale,
CCoronas::aCoronas[i].green / fogscale,
CCoronas::aCoronas[i].blue / fogscale,