--- Begin Message ---
Subject: |
[Devel] Re: FreeType performance issue |
Date: |
Tue, 28 Dec 2004 08:27:45 +0100 (CET) |
> [...]
>
> In 'ftgrays.c ' file, the 'gray_convert_glyph' function calls
> 'gray_compute_cbox' function first to get an glyph boundary.
>
> *gray_compute_cbox function costs O(n) - n is the number of points
>
> But in this time, I think FreeType can use (raster->target).width,
> (raster->target).height. I think the code can be changed like this
>
> /*gray_compute_cbox( RAS_VAR );*/ // Don't need
> raster->min_ex = 0; // Added
> raster->max_ex = (raster->target).width; // Added
> raster->min_ey = 0; // Added
> raster->max_ey = (raster->target).height; // Added
> ...
>
> Would you tell me if there is any reason that I can't do like this?
I'm not an expert in optimizing C code for speed, but your change
looks promising. After the 2.1.10 release (which should happen soon)
I invite you to contribute changes which makes FreeType faster --
please provide a patch produced with the `diff' program, using the
`-u' switch, together with a ChangeLog entry.
Thanks in advance.
Werner
_______________________________________________
Devel mailing list
address@hidden
http://www.freetype.org/mailman/listinfo/devel
--- End Message ---