mirror of https://github.com/raysan5/raylib
Update rtext.c
This commit is contained in:
parent
5604f6d8a3
commit
f5ef357810
|
@ -677,6 +677,8 @@ GlyphInfo *LoadFontData(const unsigned char *fileData, int dataSize, int fontSiz
|
||||||
{
|
{
|
||||||
stbtt_GetCodepointHMetrics(&fontInfo, ch, &chars[i].advanceX, NULL);
|
stbtt_GetCodepointHMetrics(&fontInfo, ch, &chars[i].advanceX, NULL);
|
||||||
chars[i].advanceX = (int)((float)chars[i].advanceX*scaleFactor);
|
chars[i].advanceX = (int)((float)chars[i].advanceX*scaleFactor);
|
||||||
|
|
||||||
|
if (chh > fontSize) TRACELOG(LOG_WARNING, "FONT: Character [0x%08x] size is bigger than expected font size", ch);
|
||||||
|
|
||||||
// Load characters images
|
// Load characters images
|
||||||
chars[i].image.width = chw;
|
chars[i].image.width = chw;
|
||||||
|
|
Loading…
Reference in New Issue