[cairo] text measurement in perf?

Behdad Esfahbod behdad at behdad.org
Mon May 28 17:45:52 PDT 2007

On Fri, 2007-05-25 at 11:10 -0400, Baz wrote:
> Hi,
> I'm hoping to tackle some of the issues firefox have with slow text
> measurement on the mac[1] this weekend. I've got a fix in mind, but
> perf-diff isn't going to notice it - the 'text' perf test renders
> parts of the same string repeatedly and won't ask for a lot of glyph
> measurements.
> I think I want to add a perf test for glyph-extents (rather than
> text-extents, since programs using the 'real' font api will do
> text-to-glyphs for themselves). I was thinking of taking chunks of of,
> eg, 100 glyphs at a time, filling the glyph array with sequential
> glyph ids modulo some largish number - so I'm not always hitting the
> cache - and not bothering to render the text at all.
> Does this sound reasonable? Any better ideas before I head home and code this?

Very good plan and useful for the freetype backend too.  Waiting to see


> -Baz
> [1] http://weblogs.mozillazine.org/roc/archives/2007/05/the_glyph_bound.html
> _______________________________________________
> cairo mailing list
> cairo at cairographics.org
> http://cairographics.org/cgi-bin/mailman/listinfo/cairo

"Those who would give up Essential Liberty to purchase a little
 Temporary Safety, deserve neither Liberty nor Safety."
        -- Benjamin Franklin, 1759

More information about the cairo mailing list