[Bf-taskforce25] Blendfont status and proposal.

Diego B bdiego at gmail.com
Tue Apr 28 09:44:55 CEST 2009


Hello all, this mail is to write a little about the status of blenfont
and the changes that I want to do:

First of all, blenfont can load/work with two types of fonts, the
first is freetype2 and the second
what I call "internal font", and it's the old bitmap font (intern/bmfont).

Here is where we have the first limitation, with freetype2 we can:
  * Load any font support by freetype2
  * Change the font size without limitation
  * Change the dpi (screen resolution)
  * Apply a transformation (2x2 mat) to every glyph that we load, this
is apply by the library
     so the final bitmap glyph have all the details. (we can get
better rotate text)
  * Support utf8/international

and the internal font:
  * The font are limit to what we have builtin (right now helv, helv
bold and scr)
  * The font size are limit, helv 10, 12, helv bold 8, 10, 12 and scr 12, 14, 15
  * Can't change the dpi
  * Can't apply transformations
  * Only support ascii characters


The library support two mode for draw both fonts, Texture and Bitmap.
The Texture mode have all
the new functions, rotate, blur, clipping, shadow in the other side,
the Bitmap mode still need more work.

One of the big problem is keep a nice/clean/understandable text when
we don't use the freetype2 library, this is
because the limitation of the internal font.

So.. the freetype2 library has been on Blender since a long time and I
think is time to move on.

What I want to do is remove the old internal font and always work with
freetype2, doing this freetype2
is no more optional and we can remove all the WITH_FREETYPE2.

My todo:
 1) Remove old internal font (also bmfont) and WITH_FREETYPE2
 2) Add shadow option to blenfont (move from Style to BLF)
 3) Add a "draw to buffer" function (for stamp info)
 4) Put the Bitmap mode to the same level that Texture mode (go to
keep this ? or just move to texture ?)


Comments ? Suggestion ?


More information about the Bf-taskforce25 mailing list