diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-10-29 05:13:45 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-10-29 05:14:23 +0300 |
commit | 0e71162e68939d90ff92e7ada3bf4fc11e0953ea (patch) | |
tree | 37913caaaf70405ea51397ae458c9557e651328a /source/blender/blenfont/intern | |
parent | 70947ebc65a618f2d5e156427aae59780926653c (diff) |
Cleanup: resolve cast warnings
Diffstat (limited to 'source/blender/blenfont/intern')
-rw-r--r-- | source/blender/blenfont/intern/blf_glyph.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/blenfont/intern/blf_glyph.c b/source/blender/blenfont/intern/blf_glyph.c index e077cc91f33..9170a1c0ac4 100644 --- a/source/blender/blenfont/intern/blf_glyph.c +++ b/source/blender/blenfont/intern/blf_glyph.c @@ -293,8 +293,8 @@ GlyphBLF *blf_glyph_ensure(FontBLF *font, GlyphCacheBLF *gc, uint charcode) g->advance_i = (int)g->advance; g->pos[0] = slot->bitmap_left; g->pos[1] = slot->bitmap_top; - g->dims[0] = slot->bitmap.width; - g->dims[1] = slot->bitmap.rows; + g->dims[0] = (int)slot->bitmap.width; + g->dims[1] = (int)slot->bitmap.rows; g->pitch = slot->bitmap.pitch; FT_BBox bbox; @@ -304,7 +304,7 @@ GlyphBLF *blf_glyph_ensure(FontBLF *font, GlyphCacheBLF *gc, uint charcode) g->box.ymin = ((float)bbox.yMin) / 64.0f; g->box.ymax = ((float)bbox.yMax) / 64.0f; - const int buffer_size = slot->bitmap.width * slot->bitmap.rows; + const int buffer_size = (int)(slot->bitmap.width * slot->bitmap.rows); if (buffer_size != 0) { if (font->flags & BLF_MONOCHROME) { /* Font buffer uses only 0 or 1 values, Blender expects full 0..255 range */ |