Light text is definitely a problem.

We should get the FreeType2 developers input on this (David?).

While a non-linear correction helps doing it after the contour
to greyscale rendering is very sub-optimal, read: a hack.
While this is a hack, I do admit to using a very similar
hack to sharpen text.

I will also note that for lightly contrast contrasting foreground
and background the text needs to be darkened even more. 


yao zhang wrote:
> 
> I am a fan of anti-aliased font.  Thanks to Xft/FreeType to make this
> happening on X Window machines.  I really love to see every character
> on my desktop be anti-aliased.  Because anti-aliased text is about
> good looking, it can certainly be made looking better.
> 
> I am talking about one minor but anoying problem with anti-aliased
> text: for some fonts, the characters are showing much lighter at smaller
> size than at bigger size.  Those fonts have thinner strokes.  At smaller
> size, the stroke width is less than one pixel.  The anti-aliased algorithm
> makes the stroke darkness depending on the coverage of the stroke on that
> pixel.  For those thinner stroke fonts, the anti-aliased text can not
> reach its fullest darkness and appears so light that they are almost
> indistinguishable from the white background.  Now anti-aliased text is not
> good to the eye anymore.
> 
> There is an easy fix for this.  After getting a glyph's pixel map from FT2,
> it can be enhanced by a simple table lookup.  I did some experiment and
> the results are at:
> 
> http://oto.sourceforge.net/alpha/index.html
> 
> The lookup table could be generated by
> 
> p' = 256 * (p/256) ^ alpha;    (alpha >= 1)
> 
> while alpha is a function of:
> 
> a. Font.  Thinner stroke font needs bigger alpha value;
> 
> b. Point size.  Smaller point size needs bigger alpha value.
> 
> One place to implement this is in Xft.  Before the glyph pixel map is
> blit to the surface, apply the alpha correction lookup table to the
> glyph pixel map.  The alpha value can be specified as one optional
> font property.  So something like
> 
> times-12:alpha=1.2
> 
> can be used to request the font with proper alpha correction.
> _______________________________________________
> Render mailing list
> [EMAIL PROTECTED]
> http://XFree86.Org/mailman/listinfo/render
_______________________________________________
Render mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/render

Reply via email to