summaryrefslogtreecommitdiff
path: root/Source/Core/VideoBackends/OGL/Render.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Core/VideoBackends/OGL/Render.cpp')
-rw-r--r--Source/Core/VideoBackends/OGL/Render.cpp15
1 files changed, 11 insertions, 4 deletions
diff --git a/Source/Core/VideoBackends/OGL/Render.cpp b/Source/Core/VideoBackends/OGL/Render.cpp
index 02252117fd..a0c3bb6c8d 100644
--- a/Source/Core/VideoBackends/OGL/Render.cpp
+++ b/Source/Core/VideoBackends/OGL/Render.cpp
@@ -851,10 +851,17 @@ Renderer::CreateFramebuffer(const AbstractTexture* color_attachment,
void Renderer::RenderText(const std::string& text, int left, int top, u32 color)
{
- s_raster_font->printMultilineText(text,
- left * 2.0f / static_cast<float>(m_backbuffer_width) - 1.0f,
- 1.0f - top * 2.0f / static_cast<float>(m_backbuffer_height), 0,
- m_backbuffer_width, m_backbuffer_height, color);
+ int screen_width = m_backbuffer_width;
+ int screen_height = m_backbuffer_height;
+ if (screen_width >= 2000)
+ {
+ screen_width /= 2;
+ screen_height /= 2;
+ }
+
+ s_raster_font->printMultilineText(text, left * 2.0f / static_cast<float>(screen_width) - 1.0f,
+ 1.0f - top * 2.0f / static_cast<float>(screen_height), 0,
+ screen_width, screen_height, color);
}
std::unique_ptr<AbstractShader> Renderer::CreateShaderFromSource(ShaderStage stage,