Skip to content

Commit

Permalink
Fixed compiler error/warnings created by change in FreeType
Browse files Browse the repository at this point in the history
  • Loading branch information
cschreib committed May 5, 2017
1 parent 112c4c9 commit 249a1a8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions gui/impl/gui/gl/src/gui_gl_font.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ font::font(const std::string& sFontFile, uint uiSize) : bKerning_(false)
iMaxBearingY = mFace->glyph->metrics.horiBearingY;

int iCharWidth = std::max(
mFace->glyph->bitmap.width + int(mFace->glyph->metrics.horiBearingX >> 6),
int(mFace->glyph->bitmap.width) + int(mFace->glyph->metrics.horiBearingX >> 6),
int(mFace->glyph->advance.x >> 6)
);

Expand Down Expand Up @@ -133,8 +133,8 @@ font::font(const std::string& sFontFile, uint uiSize) : bKerning_(false)
{
int iYBearing = iMaxBearingY - (mFace->glyph->metrics.horiBearingY >> 6);

for (int j = 0; j < mFace->glyph->bitmap.rows; ++j)
for (int i = 0; i < mFace->glyph->bitmap.width; ++i, ++sBuffer)
for (int j = 0; j < int(mFace->glyph->bitmap.rows); ++j)
for (int i = 0; i < int(mFace->glyph->bitmap.width); ++i, ++sBuffer)
pTexture_->set_pixel(x + i + uiXBearing, y + j + iYBearing, ub32color(255, 255, 255, *sBuffer));
}

Expand Down

0 comments on commit 249a1a8

Please sign in to comment.