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

(mgp-users 00121) embarassingly slow tfont handling...



Hi,

i think we have a small performance problem here... it is most
evident when i run mgp with truetype fonts and a not-solid background
(e.g. an image):

    rendering the slides is very slow!

On a PPro200, a 6-line paragraph on 640x480 might take some
2-3 seconds to render.  What is worse, rendering time becomes
worse and worse as time goes by, e.g. you switch back and forth
on the same pages and it takes longer and longer.

I have instrumented draw.c::draw_string() and the numbers confirm
this. Remove one of the conditions (i.e. use a solid background or X11
fonts) and the running time becomes stable.

This seems to suggest a bug in the freetype library, or at least its
interaction with magicpoint.
What is strange is that the memory occupation of the process does not
increase while running time get worse...

Any idea ?

(the thing is very embarassing because the Windows port of magicpoint
is much faster...)

	cheers
	luigi

P.S. more investigation on the problem seems to suggest that tfc_image()
is a bit suboptimal because it does one pixel at a time, however i fail
to understand why the time increases as we go on...