A New Rendering System For X

Current rendering extension protocol specification

Here's the current rendering protocol spec, I'll try to update it on a regular basis.

Anti-aliased fonts HOWTO

Download this for some brief instructions on configuring the software needed for AA text.

Example Code

The render extension bits are integrated into the regular XFree86 CVS tree. Image composition and text operations are complete, although operations other than the most basic are not optimized.

XAA has some interfaces for accelerating the lowest levels of the extension. Most of the drivers support the extension with software, the Matrox driver has some primitive hardware acceleration.

The Xft library is designed to allow applications to take advantage of the extension for text output while falling back to core text operations for servers which don't yet offer the extension. It's based on FreeType2 and you'll need the latest CVS bits to take advantage of it.

xterm has been modified to use Xft to display text, once you've got FreeType2 built and installed, add

#define Freetype2Dir /usr/local

to your config/cf/host.def file and rebuild X.

What's Next

The two big pieces remaining in the extension are polygons and image transformations; once I've got the Xft library working well enough I'll see about getting polygons running; image transformations will have to wait until after that.

Comparison using Konqueror of anti-aliased vs aliased text

Here's the same web page rendered both ways

KDE/Qt with anti-aliased text

I hacked the Qt library to use anti-aliased text. KDE looks a bit nicer

A sample X session with anti-aliased text

I took a snapshot of my desktop to demonstrate somewhat more sophisticated applications with anti-aliased text. I've already had several complaints about my choice of window managers.

Comparing anti-aliased text with bitmap text

I took the same page of text and displayed it using both techniques here

Subpixel RGB decimation vs regular anti-aliasing for LCD displays

I generated a quick sample of the effects of component-level subsampling vs regular antialiasing here.

Sample Images

All of these images were drawn inside the X server using the extension.

Two translucent squares overlapping slightly

Text rasterized with FreeType, anti-aliased and blended together.

A few nice ellipses wandering around the screen. Yes, they have fuzzy edges. These are actually core X ellipses drawn to a pixmap and blended to the frame buffer.

Xterm running with anti-aliased text (with colors!). Again, FreeType was used to generate the glyphs.

A full screen dump with translucent windows used for twm menus.