diff options
author | Diego Borghetti <bdiego@gmail.com> | 2011-02-19 16:43:22 +0300 |
---|---|---|
committer | Diego Borghetti <bdiego@gmail.com> | 2011-02-19 16:43:22 +0300 |
commit | 65ce537c6c797fac1b750c963e9563293c17d011 (patch) | |
tree | a97d2f9e359fee8c14de25591b78432592265bcc /source/blender/blenfont/intern/blf_glyph.c | |
parent | 9ee1b3930fef6404f197a56363bee4f846bc2bb7 (diff) |
Rename global_ft_lib and make it static.
Remove the XXX code from blf_glyph.c and use the pointer
inside the FontBLF struct.
If still have problem, let me know.
Diffstat (limited to 'source/blender/blenfont/intern/blf_glyph.c')
-rw-r--r-- | source/blender/blenfont/intern/blf_glyph.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/source/blender/blenfont/intern/blf_glyph.c b/source/blender/blenfont/intern/blf_glyph.c index 9a3843b960d..c29017c35f3 100644 --- a/source/blender/blenfont/intern/blf_glyph.c +++ b/source/blender/blenfont/intern/blf_glyph.c @@ -51,8 +51,6 @@ #include "blf_internal_types.h" #include "blf_internal.h" -/* XXX copied from blf_font.c */ -extern FT_Library global_ft_lib; GlyphCacheBLF *blf_glyph_cache_find(FontBLF *font, int size, int dpi) { @@ -236,9 +234,9 @@ GlyphBLF *blf_glyph_add(FontBLF *font, unsigned int index, unsigned int c) /* Convert result from 1 bit per pixel to 8 bit per pixel */ /* Accum errors for later, fine if not interested beyond "ok vs any error" */ FT_Bitmap_New(&tempbitmap); - err += FT_Bitmap_Convert(global_ft_lib, &slot->bitmap, &tempbitmap, 1); /* Does Blender use Pitch 1 always? It works so far */ - err += FT_Bitmap_Copy(global_ft_lib, &tempbitmap, &slot->bitmap); - err += FT_Bitmap_Done(global_ft_lib, &tempbitmap); + err += FT_Bitmap_Convert(font->ft_lib, &slot->bitmap, &tempbitmap, 1); /* Does Blender use Pitch 1 always? It works so far */ + err += FT_Bitmap_Copy(font->ft_lib, &tempbitmap, &slot->bitmap); + err += FT_Bitmap_Done(font->ft_lib, &tempbitmap); } else { err = FT_Render_Glyph(slot, FT_RENDER_MODE_NORMAL); } |