diff options
author | Diego Borghetti <bdiego@gmail.com> | 2009-05-06 03:10:32 +0400 |
---|---|---|
committer | Diego Borghetti <bdiego@gmail.com> | 2009-05-06 03:10:32 +0400 |
commit | 405cf80eb8dc2df8ae160aee70aef34052add24a (patch) | |
tree | f03cc27e95bdf91b25ea9d2a0dffb28ccef666be /source/blender/editors/space_view3d/drawarmature.c | |
parent | 71c38978e14ebf3522fe60fc239ad04f10ef30ab (diff) |
Big, big commit!!
1) Remove WITH_FREETYPE2 from code, so now blender always need freetype2
2) Remove the old bmfont
3) Remove ftfont and bFTGL library
4) Implement a new BLF_draw_default function for place that still need/use
the old BMF api.
I try to update both, scons and cmake, but I only can test with make, so
hope all work fine.
MSVC is broken, but I don't have Windows, things to search and fix are
any reference to WITH_FREETYPE2, FTGL and BMFONT (take in care that
blenkernel also have a BKE_bmfont.h, this don't have anything to do with bmfont).
Always have to link/include the freetype2 library
Remove any reference to libbmfont
Remove any reference to libftfont
Remove any reference to libbftgl (or libbFTGL)
Diffstat (limited to 'source/blender/editors/space_view3d/drawarmature.c')
-rw-r--r-- | source/blender/editors/space_view3d/drawarmature.c | 21 |
1 files changed, 8 insertions, 13 deletions
diff --git a/source/blender/editors/space_view3d/drawarmature.c b/source/blender/editors/space_view3d/drawarmature.c index 5d130cee48d..dfdd70b11e7 100644 --- a/source/blender/editors/space_view3d/drawarmature.c +++ b/source/blender/editors/space_view3d/drawarmature.c @@ -37,8 +37,6 @@ #include "MEM_guardedalloc.h" -#include "BMF_Api.h" - #include "DNA_action_types.h" #include "DNA_armature_types.h" #include "DNA_constraint_types.h" @@ -74,6 +72,7 @@ #include "WM_api.h" #include "WM_types.h" +#include "BLF_api.h" #include "UI_resources.h" @@ -1806,9 +1805,8 @@ static void draw_pose_channels(Scene *scene, View3D *v3d, RegionView3D *rv3d, Ba /* Draw names of bone */ if (arm->flag & ARM_DRAWNAMES) { VecMidf(vec, pchan->pose_head, pchan->pose_tail); - glRasterPos3fv(vec); - BMF_DrawString(G.font, " "); - BMF_DrawString(G.font, pchan->name); + BLF_draw_default(vec[0], vec[1], vec[2], " "); + BLF_draw_default(vec[0] + BLF_width_default(" "), vec[1], vec[2], pchan->name); } /* Draw additional axes on the bone tail */ @@ -1993,8 +1991,8 @@ static void draw_ebones(View3D *v3d, RegionView3D *rv3d, Object *ob, int dt) if (arm->flag & ARM_DRAWNAMES) { VecMidf(vec, eBone->head, eBone->tail); glRasterPos3fv(vec); - BMF_DrawString(G.font, " "); - BMF_DrawString(G.font, eBone->name); + BLF_draw_default(vec[0], vec[1], vec[2], " "); + BLF_draw_default(vec[0] + BLF_width_default(" "), vec[1], vec[2], eBone->name); } /* Draw additional axes */ if (arm->flag & ARM_DRAWAXES) { @@ -2155,15 +2153,13 @@ static void draw_pose_paths(Scene *scene, View3D *v3d, RegionView3D *rv3d, Objec /* only draw framenum if several consecutive highlighted points don't occur on same point */ if (a == 0) { - glRasterPos3fv(fp); sprintf(str, " %d\n", (a+sfra)); - BMF_DrawString(G.font, str); + BLF_draw_default(fp[0], fp[1], fp[2], str); } else if ((a > stepsize) && (a < len-stepsize)) { if ((VecEqual(fp, fp-(stepsize*3))==0) || (VecEqual(fp, fp+(stepsize*3))==0)) { - glRasterPos3fv(fp); sprintf(str, " %d\n", (a+sfra)); - BMF_DrawString(G.font, str); + BLF_draw_default(fp[0], fp[1], fp[2], str); } } } @@ -2205,9 +2201,8 @@ static void draw_pose_paths(Scene *scene, View3D *v3d, RegionView3D *rv3d, Objec if (ak->cfra == (a+sfra)) { char str[32]; - glRasterPos3fv(fp); sprintf(str, " %d\n", (a+sfra)); - BMF_DrawString(G.font, str); + BLF_draw_default(fp[0], fp[1], fp[2], str); } } } |