From ede60da544cf8374d32b01b211ad929edccae863 Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Sat, 12 May 2018 19:25:57 +0200 Subject: [PATCH] source/Graphics/Font/FreeTypeDriver.cpp: get rid of some compiler warnings by proper casting. --- source/Graphics/Font/FreeTypeDriver.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/source/Graphics/Font/FreeTypeDriver.cpp b/source/Graphics/Font/FreeTypeDriver.cpp index 7fbeba3..a6946b9 100644 --- a/source/Graphics/Font/FreeTypeDriver.cpp +++ b/source/Graphics/Font/FreeTypeDriver.cpp @@ -148,10 +148,10 @@ Font::Glyph FreeTypeDriver::loadGlyph(unsigned int codepoint, Image& img, unsign bmp.rows, bmp.buffer); - glyph.offset.x = metrics.horiBearingX / (1 << 6); - glyph.offset.y = metrics.horiBearingY / (1 << 6); - glyph.size.x = (metrics.width / (1 << 6)) + (outlineSize * 2); - glyph.size.y = (metrics.height / (1 << 6)) + (outlineSize * 2); + glyph.offset.x = static_cast(metrics.horiBearingX / (1 << 6)); + glyph.offset.y = static_cast(metrics.horiBearingY / (1 << 6)); + glyph.size.x = static_cast(metrics.width / (1 << 6)) + (outlineSize * 2); + glyph.size.y = static_cast(metrics.height / (1 << 6)) + (outlineSize * 2); } glyph.advance = static_cast(metrics.horiAdvance >> 6) + (outlineSize * 2);