freetype
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft] Glyph Advance when using the Image Cache


From: Werner LEMBERG
Subject: Re: [ft] Glyph Advance when using the Image Cache
Date: Fri, 14 Jul 2006 07:24:38 +0200 (CEST)

> If I bypass the image cache and just use FT_Load_Glyph, then the
> glyphs are correctly loaded in the the GlyphSlot. However, when I
> use FTC_ImageCache_Lookup, the advance vector in the glyph does not
> appear to be set correctly. For example, when using a size 22 Arial
> font, the asvance.x = 917504, and advance.y = 0. When I use
> FT_Load_Glyph, I get a more reasonable value of advance.x = 896. If
> you look at these numbers, 917504 / 896 = 1024, so I've noticed that
> if I copy the glyph I get from FTC_ImageCache_Lookup, then divide
> its advance.x by 1024, then it seems to work.

Well, the former value looks like being in font units, while the
latter appears to be a 26.6 fractional pixel value.  The question is
how to explain the difference.

Please provide a small (compilable) code snippet which shows the
problematic behaviour.  Maybe there's a buglet, or the documentation
lacks a proper explanation.


      Werner




reply via email to

[Prev in Thread] Current Thread [Next in Thread]