While we don't have proper DPI checking, double overlay size on android

This commit is contained in:
baldurk
2018-01-22 18:35:22 +00:00
parent f0015f4b77
commit e0aedf1f5b
2 changed files with 11 additions and 0 deletions
+7
View File
@@ -322,6 +322,9 @@ void WrappedOpenGL::ContextData::CreateDebugData(const GLHookSet &gl)
firstChar, numChars, chardata);
CharSize = charPixelHeight;
#if ENABLED(RDOC_ANDROID)
CharSize *= 2.0f;
#endif
CharAspect = chardata->xadvance / charPixelHeight;
stbtt_fontinfo f = {0};
@@ -722,6 +725,10 @@ void WrappedOpenGL::RenderOverlayStr(float x, float y, const char *text)
y += 1.0f;
y *= charPixelHeight;
#if ENABLED(RDOC_ANDROID)
y *= 2.0f;
#endif
float startx = x;
float starty = y;
@@ -304,6 +304,10 @@ VulkanTextRenderer::VulkanTextRenderer(WrappedVulkan *driver)
stbtt_BakeFontBitmap(ttfdata, 0, pixelHeight, buf, width, height, firstChar, numChars, chardata);
m_FontCharSize = pixelHeight;
#if ENABLED(RDOC_ANDROID)
m_FontCharSize *= 2.0f;
#endif
m_FontCharAspect = chardata->xadvance / pixelHeight;
stbtt_fontinfo f = {0};