aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/libui_sdl/main.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/libui_sdl/main.cpp b/src/libui_sdl/main.cpp
index 23e6617..dc67bb2 100644
--- a/src/libui_sdl/main.cpp
+++ b/src/libui_sdl/main.cpp
@@ -223,8 +223,6 @@ void GLDrawing_DrawScreen()
glUnmapBuffer(GL_UNIFORM_BUFFER);
float scwidth, scheight;
- scwidth = 512;
- scheight = 384;
float x0, y0, x1, y1;
float s0, s1, s2, s3;
@@ -241,6 +239,9 @@ void GLDrawing_DrawScreen()
x1 = TopScreenRect.X + TopScreenRect.Width;
y1 = TopScreenRect.Y + TopScreenRect.Height;
+ scwidth = 256 << ScreenScale[0];
+ scheight = 192 << ScreenScale[0];
+
switch (ScreenRotation)
{
case 0:
@@ -279,13 +280,14 @@ void GLDrawing_DrawScreen()
SETVERTEX(4, x0, y1, s2, t2);
SETVERTEX(5, x1, y1, s3, t3);
- // TODO: adjust scwidth/scheight
-
x0 = BottomScreenRect.X;
y0 = BottomScreenRect.Y;
x1 = BottomScreenRect.X + BottomScreenRect.Width;
y1 = BottomScreenRect.Y + BottomScreenRect.Height;
+ scwidth = 256 << ScreenScale[1];
+ scheight = 192 << ScreenScale[1];
+
switch (ScreenRotation)
{
case 0: