With common graphics hardware and some bleeding-edge software, Linux can exceed both Mac OS X and Vista with its gee-whiz desktop special effects. Here’s how to impress your friends, wow your neighbors, and influence the public with Beryl.
Let’s face it: Although many of us are full-time, dyed-in-the-wool Linux users, we all have a little envy — okay, maybe a lot of envy — of the eye candy available on other operating systems. The Mac OS X desktop is beautiful, and while Windows Vista is a truly bloated system with ridiculous hardware requirements, its Aero Glass 3D-accelerated desktop looks very nice, indeed. Yeah, Linux is more stable, more secure, more agile, and open source, but sometimes you just want to impress your friends and co-workers with a little razzle dazzle, especially if you’re the local open source evangelist. It’s all about the marketing.
Fortunately, Mac OS X and Aero Glass aren’t the only pretty desktops around. With common graphics hardware and some bleeding-edge software, Linux can also produce impressive 3D, composite, and alpha-blended desktops. In fact, Linux can exceed both Mac OS X and Vista with its gee-whiz desktop special effects.
FIGURE ONE: An example of Beryl’s animation features
Because much of this stuff is still in its infancy, there is naturally some confusion about the system requirements for using sophisticated window managers on your Linux distribution. Let’s talk a bit about the technologies and software behind the cutting-edge desktops, and then dive into the nuts and bolts of tweaking your system.
Bleeding Edge Compositing
To run a compositing window manager on your system, you must have accelerated 3D graphics hardware. If your system is more than three years old, you might not want to attempt this.
FIGURE TWO: Beryl can animate and composite images
At a bare minimum, you need an AGP 2X nVidia GeForce or ATI Radeon card with 64 MB of VRAM; optimally, install a PCI-X version of either of those two chip sets with 128 MB or more of VRAM. Mobile versions of the nVidia or ATI Radeon, as well as the newer Intel chipsets on Centrino and Core Duo laptops, are also suitable. (Support of graphics cards and OpenGL direct/indirect rendering under the X Window System varies from one Linux distribution to another. You can find a pretty good list of supported hardware at the Gentoo Linux Wiki, at http://gentoo-wiki.com/HARDWARE_Video_Card_Support_Under_XGL.)
FIGURE THREE: Windows can be opaque or partially transparent
*Xgl was developed internally at Novell and was released as an open source project with SUSE Linux Enterprise Desktop 10 in January 2006. It was the first of the compositing rendering engines, and was designed to take advantage of video cards with proprietary, closed-source, accelerated, and 3D X Window System (X) drivers, such as those provided with the GeForce and Radeon cards. (If you’re inclined to use OpenSUSE, take a look at the latest 10.2 distro at http://www.opensuse.org, and read the fine documentation at the OpenSUSE wiki, available worldwide at http://en.opensuse.org/Using_Xgl_on_SUSE_Linux.)
*AIGXL was created in response to Xgl, and expressly eschews proprietary drivers. Unlike Xgl, which uses the direct rendering infrastructure and 3D extensions found in proprietary drivers, AIGLX is an indirect rendering infrastructure. Developed as part of X.org, AIGLX provides an abstraction layer and a programming interface that relay OpenGL commands from the compositing window manager and OpenGL-aware applications to the graphics card itself — not unlike the way DirectX and Direct3D works on Windows Vista. Potentially, AIGXL allows for much broader hardware support, simplified software development, and the use of open source video hardware drivers.
At press time, Intel is the only vendor to release its accelerated, 3D X drivers as open source to work with AIGLX. An independent, open source nVidia driver project, Nouveau (http://nouveau.freedesktop.org/wiki/) has recently been founded to re-engineer the acceleration of the GeForce chipsets, although nothing is currently working. While the basic, open source radeon and nvidia drivers built into X.org run with compositing window managers on AIGLX, both of those drivers’ performance and features lag the respective closed-source counterparts.
*Compiz, also written by Novell, was initially designed to take advantage of the direct rendering features of Xgl, but now also works with X.org installs with AIGLX enabled. For example, both Fedora Core 6 and Ubuntu Edgy have AIGLX enabled by default.
*Beryl was forked from the Compiz project in September of 2006 following technical and creative differences, and now appears to be gathering a lot of developer interest on non-Novell distributions. An official Beryl distro, Sabayon, is based on Gentoo Linux, and has garnered a reputation for being on the most bleeding edge of Beryl and other open source software builds. You can download Sabayon at http://sabayonlinux.org/.
FIGURE FOUR: Let it snow! Let it snow! Let it snow!
Given capable graphics hardware, a rendering engine, and a compositing window manager, you can have the wildest desktop in town. Let’s install Beryl on Ubuntu.
Beryl and Edgy
The install that follows assumes that you’re running Ubuntu Edgy 6.10 and that you’ve updated your machine to include all current updates and fixes. (If not, read “Tweaking Ubuntu” on the Linux Magazine Web site at http://www.linux-mag.com/id/2782.) Next, depending on your graphics card you have, you may need to modify Listing One:
Listing One: A Beryl install script, with nVidia-specific lines highlighted in bold text
By default, the install script fully configures a system that uses a nVidia graphics card for use with Xgl. If you have an ATI Radeon card or the Intel Core Duo/Centrino mobile graphics chipset, comment out or delete Lines 8-11.
FIGURE FIVE: Measuring frame rate of a desktop animation
To run the script, save it to your home directory as beryl-install-script.sh, run chmod 755~/beryl-install-script from a terminal window, and then run sudo./beryl-install-script. After the script finishes, verify that your /etc/X11/xorg.conf file has been modified accordingly. You should see the following snippet within the Module section for nVidia cards:
If you see nv instead of nvidia for the Driver parameter, you’ve got the wrong driver. Change the entry manually, because the built-in nv driver lacks OpenGL acceleration.
For ATI Radeon-based systems, the Driver parameter must be radeon and not ati. The radeon driver is built into X.org and yields decent alpha blending and compositing performance. However, if you want optimal performance, use the proprietary fglrx driver. To install the fglrx driver, open up a terminal window and type: