David Chester writes: “On my website, I propose some enhancements to the FreeType font rendering library. The changes are aimed at rendering antialiased text at small sizes. I explain an alternate stem-alignment algorithm as well as a new hinting configuration which balances contrast and loyalty to the original shape of the glyph. At the site there’s explanation and examples, as well as patches and a binary for download.”
I’ve been applying this patch on all my systems for awhile, and I must say that it is a marked improvement over the default Freetype rendering. Here’s a screen shot of OSnews being rendered in Opera with Xft and Freetype with this patch:
http://fails.org/freetype.png
I’d say that’s at least on par with if not surpassing OS X and ClearType.
David now suggests a new one. And your site doesn’t seem to load here.
The image [ http://fails.org/freetype.png ] does NOT load
It works for me. Did he change something?
David Chester has been doing some awesome stuff with Freetype. Font de-uglification is now almost user-friendly.
to get a better appreciation of the differences between methods in David’s examples at
http://www.cs.mcgill.ca/~dchest/xfthack/smoothtext.html
.. that’s what the world needs (I’m not joking )
It was really a hard time for my eyes to look at a linux-screen before
…I almost prefer the initial “no hinting whatsover” example. Oh, and I had no trouble viewing the freetype.png in the initial comment…
That is very impressive, I would agree it would be at par with OS X’s default rendering setting and it does look a lot better than cleartype. But if you set OS X to a Strong smoothing style you’ll definitely see some beautiful fonts.
That’s my personal experience I have a 21″ Trinitron monitor (SGI), so it might look different on other screens.
I dunno, from what I remember of it and side-by-side screenshots I’d say the freetype rendering on redhat 8 is much better than MacOS. It doesn’t feel so heavy, but still makes the fonts look great. That might just be personal preference, but I think the current one is better than OS X and ClearType.
Isn’t CT meant for LCDs anyway? I switched on antialiasing in Windows XP and it didn’t seem to do anything except the title bars. ClearType did stuff, but the colours looked a bit odd.
Would it be possible to use the graphics card to do the anti-aliasing?
Are there any Mozilla Xft builds out there? I seem to remember a Red Hat one but I’d like a .deb.
Risc OS has had anti-aliasing for many many years…
http://www.vigay.com/cgi-bin/r?a=fonts
AA in WinXP only AAs font sizes that are large or small. I don’t know the exact font sizes offhand, but I think they’re around < 6pt and >12pt (but different if bold I think).
And, yes, I believe CT is meant for LCD monitors, although it seems several people with CRTs like it too.
nice warning for Windows XP users….
excuse the newbie but does this work with redhat 8 or does the font preferences mess it up because of the hinting settings and fontconfig
When I got my new Inspiron laptop, anti-aliasing suddenly became an important thing for me. The 15″ screen has a 1600×1200 resolution, which places it at 133 DPI. Such a high resolution screen is abosolutely wonderful for those who spend a lot of time looking at text, because at that resolution, text becomes more than one pixel thick, and font shapes improve immensely. However, the screen exposed a lot of problems with available font renderers, and it took a bit of searching to get things set of perfectly. This is just a list of some things I’ve found:
1) Bytecode hinting isn’t the no-brainer it used to be. For most screens, I would still leave it on, but it absolutely kills readability on a high res screen. It snaps lines to one pixel, which makes text very hard to see. A high res LCD has enough pixels where even people who don’t like small font sizes anti-aliased should still use anti-aliasing, since the bluriness isn’t noticable.
2) The new autohinter in freetype 2.1.3 is a huge improvement over previous iterations, and it blows away the bytecode interpeter on my screen. The extra pixels seem to let it show its stuff. For those used to more Windows-style rendering, I’d still try the auto-hinter first, and if that is unacceptable, use the bytecode one. These improvements to the autohinter (these are actual algorithm improvements, so the Xft-hack name is totally inappropriate, it has nothing to do with Xft and isn’t a hack looks like it’ll polish up a few of the rough edges. The only thing really left to work on at this point is auto-hinting italicized text, and auto-hinting non-English glyph sets.
3) Postscript fonts help. Some of the improvements in the 2.1.3 FreeType seem to apply to the postscript hinter. This is actually a nice thing, because designing a good postscript font is a huge deal easier than designing a good TrueType font, so the range of font choices opens up quite a bit. I’ve advertised this before, but it’s worth saying again: Springing for the $99 Adobe Type Basics font collections is probably one of the better $99 you’ll spend.
4) FreeType rocks. At this point, FreeType outdoes OS X and Windows for almost every workload. FreeType’s LCD optimized rendering is better than ClearType’s because it’s algorithm decreases color fringes quite a bit more. It’s un anti-aliased hinted output is exactly equivilent (if using the TT interpreter). It’s regular anti-aliased output is probably on a par, except for italicized rendering, where Windows is far superior. I personally hate OS X’s text rendering (I hated Xft-hack’s too, so it seems to be something of personal preference). Unhinted text looks terrible. Black balance (the evenness of the ‘ink’ weight) just dies without hinting. Rendering without hinting is far too fuzzy on my 133dpi LCD. It’s just not appropriate for a 90-something DPI LCD (like they ship with the iMac…) This is less visible on an analog device like a CRT, which renders fuzzy anyway (even good Trinitons like I used to use) but is blatent on a digital device like an LCD. FreeType’s rendering keeps most of the advantages of no-hinting (much better letter shape) but without making things too fuzzy. In real life (ie. staring at code for hours a day) the latter is more important than the former anway.
5) Speaking of LCD optimized rendering, think before enabling it. Because FreeType renders pretty sharply to begin with, it really don’t improve text all that much. It’s a subtle effect, mostly. However, with Xft, enabling LCD optimized rendering uses a special blending mode that current graphics cards don’t accelerate. This mode results in significantly better looking text, but the loss of acceleration kills performance, making text selection very choppy even on a 2GHz P4. Leaving it off (as I’ve had to, since FT 2.1.3 breaks LCD optimized rendering anyway) works just fine.
6) This should definately all be configurable. I know Eugenia will hate me suggesting a big complex set of options like this, but this is very important. Text rendering is a very personal thing (like socks). There is no one-size fits all way to do it. People are spending a lot more time in front of their computers these days, and it’s not worth destroying their eyes to gain a little ease of use. Something like RedHat’s font config dialog, which shows several lines each rendered with different options, and asks the user to pick the one they like best is definately the way to go.
now i have much better anti-aliased fonts in RH8.0
I must say that if I compare Bascules freetype.png with my Windows XP cleartype rendering on my laptop, this cleartype looks really slick and Bascule’s looks much bolder.
I don’t know if it’s because I use an LCD screen, but I highly prefer cleartype here.
If you goto my site: http://home.iprimus.com.au/matgarnz and click on the Linux link, you will find a link to the Freetype-2.1.3 SRPM and two RPMs with every cool feature enabled. The binaries are compiled on UNITED Linux/SCO Linux 4.0 using GCC 3.2
Does anyone know how to install the patch?
Thanks
Am I the only person left on the planet who doesn’t like anti-aliasing at “normal” font-sizes?
I find it much easier to read non-antialiased fonts (aliased?) at sizes of around 8pt to 12pt, with anti-aliasing turned on for all bold text, and small & large sizes (very easy to do now with fontconfig/xft2)
???
No you arnt.
Antialised fonts just look to thick and crap in comparision ot non anti alisased fonts. Especially at the font sizes you specify.
That’s why fonts in windows looks _SO_ much better than in linux, everything in X is blurred to shit (also known as ‘antialiasing’, in windows it’s snapped crisp to the pixel boundary.
No, you are not the only one. With redhat 8’s rendering i can tolerate even those sizes being antialiased, with most other systems, the blurryness that they introduce is enough to make me not want to work on that system unless it can be turned off. I did eventually switch it off for redhat too, except for 16+ pts. (i could have added < 6 pts too, but i really dont want any fonts that small anyway as they are darn hard to read no matter what. 6/72 inch or 0.21 mm is too darn small.)
And as a side thing, i find it funny how many people prefer cleartype on their CRTs. I think they must either have a worse eyesight than me (which is very hard to believe actually:-), or crappy CRTs that are blurry already. This could be the truth as most monitors that come bundled with a PC tends to be the weakest link of the system, along with the keyboard and mouse, which i find is very unfortunate, as those are the only parts that is actually used directly.
But i guess this isnt unique, i also see lots of people claiming that mp3 sounds just as good as the original CD, and i know people who have spent a fortune on stereo equipment, only to hook it up with cheap speakers, or if they actually do get decent speakers, they use the refence cables that came with the stereo. (as in those black cables with red and white plugs, that are not really meant to be used)
My point is, that for most things there are different tastes, and often everyone have varying scales when judging something. (as in to some an mp3 and a cd might sound alike, while to others there is a large difference), and as long as everyone are happy, things are fine and dandy, no matter what people like me think about antialiasing being blurry, and bundled audio cables killing the sound 🙂
And as a side thing, i find it funny how many people prefer cleartype on their CRTs. I think they must either have a worse eyesight than me (which is very hard to believe actually:-), or crappy CRTs that are blurry already.
—————–
I am using a 17″ Sony Trintron. In XP, when I use the ‘standard’ font rendering scheme – it looks like crap. The fonts are jagged and square looking. When I turn on ClearType it looks awesome.
This is not a low buget monitor !
ClearType in my opinion is 100 x better than OS X and OS X is 100 x better than FreeType. Now i admit that I think OS X is a bit ‘heavy’ but the inconsistency in FreeType fonts especially on the letters ‘e’ and ‘f’ drive me crazy and thus making OS X font rendering scheme better.
This patch ‘looks’ really good. Now if someone could just inform me how to update this on my RedHat 8.0 machine, I would greatly appreciate it
Are you serious? This screen shot seems to show reeeally messed up letters here, and yes, I did full-size the picture. I cannot belief that what I see is what you’ve got… maybe you can upload another one..?
This patch ‘looks’ really good. Now if someone could just inform me how to update this on my RedHat 8.0 machine, I would greatly appreciate it.
As I say on the site, there are instructions in the README file, but here is one way to install this specifically for Red Hat 8:
Download the ft-smooth file from the site, and untar it in your home directory:
$ tar zxvf ft-smooth-20021210.tar.gz
then logout of X, then change to root:
$ su
make a backup of the original libfreetype:
# mv /usr/lib/libfreetype.so.6.3.1 ~<user>/libfreetype.orig
(insert your regular username for <user> above)
copy the new libfreetype into place:
# cd /usr/lib
# cp ~<user>/ft-smooth-20021210/libfreetype.so.6.3.2 .
update the symlink:
# rm libfreetype.so.6
# ln -s libfreetype.so.6.3.2 libfreetype.so.6
then exit to the normal user, and restart X.
You might want to strip the library using ‘strip -s libfreetype.so.6.3.2’. Saves some diskspace and maybe speeds up executing?
Regarding Cooltype: it really is meant for LCD displays!
See http://www.adobe.com/products/acrobat/cooltype.html for a very clear explanation.
Extracted from this page:
“CoolType creates clearer, crisper type using a font-rendering technique called color anti-aliasing, which works on digital liquid crystal display (LCD) screens such as those in laptops, handheld devices, and flat-panel desktop monitors. Unlike conventional anti-aliasing, which manipulates only whole pixels, CoolType controls the individual red, green, and blue subpixels on a digital LCD screen.”
To get an even better appreciation of the improvements, switch between these images:
http://www.cs.mcgill.ca/~dchest/xfthack/gpl-213.png
Default configuration in FreeType 2.1.3
http://www.cs.mcgill.ca/~dchest/xfthack/gpl-smooth.png
Dave’s hack
It is *definitely* better than the default configuration. I could actually see myself using anti-aliased fonts in Linux with this hack. So why isn’t this default? What are they waiting for?
I notice in some apps, particularly Microsofts’ and buddies (Corel, for example) do use ClearType, while others don’t. But one thing I have notice is that ClearType is never used on any application in the menubar. Maybe the menu entries, but the menubar text is ugly and not antialiased.
Amazing isn’t it, a year ago I would prefer reading of Windows XP or Mac OS (X or 9), right now I prefer using KDE 3.1 RC3 with QT 3.1 (using XFT2, and obviously FreeType).
I know and I realize that ClearType is designed for LCDs but no matter what monitor (CRT) I have tried it on – it looks GREAT.
ClearType is in my opinion superior to ALL rendering methods. Apple was always a leg up on fonts over Microsoft until XP was released.
You are kidding, right? Though matter what CRT monitor I use, I never got ClearType to work. The analog ones give a error, but the digital ones give some junk that is completely unreadable. It is a interesting new way of doing things compared to FreeType and Apple’s method, but it is still at its infantcy.
Besides, comparing side to side, I would say FreeType 2 wins hands down. Of course, my LCD monitor is a low cost 92dpi monitor and I still wonder how it looks on better LCD monitors (meaning more expensive LCD monitors).
IMHO, ClearType looks the best… There’s also, options to control how cleartype looks (via MS website or some 3rt party program…), but I prefer the default rendering. by the way I still on a CRT monitor… Also, I’m using daily MacOS X at work (on a LCD monitor), but still prefering ClearType, looks more natural to me…
About ClearType working or not… Some developers specify the font for their programs instead of leaving the default system (‘MS Shell Dlg’ virtual font); when they do that, ClearType isn’t used as usually… and doing that’s bad for multilanguage systems too…
Also, this discusing’s lot about personal taste. I would like to know also how the fonts compare to the official TrueType specification…