Hello everybody,
we've noticed repeated file access by the small bitmap cache when
looking up the blank character (code 32). Our rendering engine iterates
over the string to be printed, calling FTC_SBitCache_Lookup() to obtain
the glyph for each character. The problem seems to be that for the blank
there is no glyph image, which makes sense, but we need the x advance.
When performing this look-up FreeType accesses the file each time.
We've supplied our own callbacks for file access which made it easy to
determine that this is the source of some major slowdowns, especially
when the fonts are stored on slow media (like SD cards).
We currently have a workaround in place that stores the x advance for
each size in our application. But we would like to avoid this kind of
thing. So the question is, is this a bug, or are we not using the API
correctly? We suspect that since there is no glyph image (or its width
and height is 0) the cache assumes that it needs to create the glyph and
therefore opens the file over and over again.
Kind regards,
Ingmar Frank
_______________________________________________
Freetype mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/freetype