RE: high-level text drawing



On Mon, 2003-12-29 at 14:27, Tom Liu wrote:
With your program to test on my machine,
      If I use the "Fixed" font, pango is ~21 times slower.
      If I use default font pango is ~268 times slower.
My tester is slower should be the network,
      My Xserver is Exceed runs on a P4 2.6GHZ, Xclient is SUN box.

You are testing the worst possible thing, I think - drawing
anti-aliased text across the network without the RENDER extension. Xft
has to fetch the area under the text to composite each string
against. This is naturally really slow - you have a round
trip across the network for each drawing call. Really nothing
to do with Pango.

I did some patches to GDK and Xft at one point to fix this:
http://mail.gnome.org/archives/gtk-devel-list/2003-March/msg00045.html

But it never really went anywhere. Hopefully Cairo will provide
a better forum for achieving such things.

I'd also say, that "how much slower is pango than XDrawString"
is never a useful question. It's not really comparable, because
the capabilities of Pango are entirely different than XDrawString.
If you just need XDrawString, use XDrawString!

The question is whether Pango is drawing text fast enough for
your application, and if not, how that can be fixed. How fast
do you need to draw text?

Regards,
                                                Owen





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