freetype
[Top][All Lists]
Advanced

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

[Freetype] Reducing load time of ft_load_glyph


From: Rich Stephens
Subject: [Freetype] Reducing load time of ft_load_glyph
Date: Mon, 26 Aug 2002 11:31:50 -0400

Since I got no response on this from the freetype devel mailing list, I
thought I'd try the general list... 

We are using freetype ONLY for the purpose of loading metrics information
for TTF/OTF files. 
We call ft_new_face() once for each TTF we are loading, and then we run
through the unicode character map and get the metrics information for each
glyph that exists using a loop of FT_Get_First_Char and FT_Load_Glyph. 

We are not actually drawing the characters or using any bitmap information
or other glyph drawing information other thanthe actual metrics themselves
(metrics.horiAdvance, metrics.width, metrics.horiBearingX for each glyph,
along with a few other values that are not on a per-glyph basis. 

All this information is loaded into a TTF structure, and no other freetype
code is ever called again for a particular TTF font.

This means (I think) that the caching method that was implemented recently
really doesn't help us. 
When checking our application's run with TrueTime (on Windows, although are
application is also ported to 3 Unix platforms as well), we have found that
when we are using a TTF, FT_Load_Glyph makes up a huge percentage of our
running time. 

Is there any way, knowing the minimal information we are retrieving from the
TTF, to reduce the time it takes for FT_Load_Glyph?  Any options we can set
to cut out the loading of information we aren't using (like bitmaps, as an
example)?



Rich Stephens 
Software Developer 
Optio Software, Inc. 
Windward Fairways II 
3015 Windward Plaza 
Alpharetta, GA 30005 
(770) 576-3561 
address@hidden 



reply via email to

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