Skip to content

Commit

Permalink
Update rtext.c
Browse files Browse the repository at this point in the history
  • Loading branch information
raysan5 committed Feb 4, 2024
1 parent c0c2e28 commit e9291fa
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/rtext.c
Original file line number Diff line number Diff line change
Expand Up @@ -2368,11 +2368,11 @@ static GlyphInfo *LoadFontDataBDF(const unsigned char *fileData, int dataSize, i

for (int bitX = 0; bitX < 4; bitX++)
{
int pixelX = ((x * 4) + bitX);
int pixelX = ((x*4) + bitX);

if (pixelX >= charGlyphInfo->image.width) break;

if ((byte & (8 >> bitX)) > 0) ((unsigned char*)charGlyphInfo->image.data)[(pixelY * charGlyphInfo->image.width) + pixelX] = 255;
if ((byte & (8 >> bitX)) > 0) ((unsigned char *)charGlyphInfo->image.data)[(pixelY*charGlyphInfo->image.width) + pixelX] = 255;
}
}
}
Expand Down Expand Up @@ -2423,7 +2423,7 @@ static GlyphInfo *LoadFontDataBDF(const unsigned char *fileData, int dataSize, i
charGlyphInfo->offsetY = fontBBh - (charBBh + charBByoff0 + fontBByoff0 + fontAscent);
charGlyphInfo->advanceX = charDWidthX;

charGlyphInfo->image.data = RL_CALLOC(charBBw * charBBh, 1);
charGlyphInfo->image.data = RL_CALLOC(charBBw*charBBh, 1);
charGlyphInfo->image.width = charBBw;
charGlyphInfo->image.height = charBBh;
charGlyphInfo->image.mipmaps = 1;
Expand Down

0 comments on commit e9291fa

Please sign in to comment.