David Herrmann <[email protected]> writes:

>> You could speed this up by caching the glyphs in a pixman_glyphs_t
>> structure and then using pixman_composite_glyphs(), or if you are sure
>> that your glyphs will never overlap each other,
>> pixman_composite_glyphs_no_mask().
>
> I already cache the glyphs in a hash-table that works pretty well.
> Also "perf" shows me that the glyph-lookup makes only 2% of the
> rendering-time. Does the pixman_glyph cache do more than that? Any
> other magic I am not aware of? Or is it a simple hash table? Because
> then I will probably stick with my own implementation.

The benefit of pixman_glyph_cache_t is that it avoids some overhead in
pixman_image_composite32(). For example, it only computes the composite
region once, and usually only does the fast path lookup once. For small
images like glyphs such overhead can be significant compared to the
actual compositing.


Søren
_______________________________________________
Pixman mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/pixman

Reply via email to