Chinaunix首页 | 论坛 | 博客
  • 博客访问: 890775
  • 博文数量: 139
  • 博客积分: 10016
  • 博客等级: 上将
  • 技术积分: 932
  • 用 户 组: 普通用户
  • 注册时间: 2005-07-31 02:15
文章存档

2008年(19)

2007年(73)

2006年(46)

2005年(1)

我的朋友

分类: LINUX

2006-11-18 11:47:01

Xgl and AIGLX has been a hot topic lately so here's a guide to get it working at home :cool:
Now, what's the difference between AIGLX, Xgl? Between Compiz, and Beryl? Well, it's a good question. I've made little sections below with explanations.
AIGLX & Xgl
I've done a bit of research, and from my understanding, (post if I'm wrong) Fedora Core and almost every other Linux else out there uses some sort of a 'X server' to display graphics.
In our case, it's called Xorg. Basically programs connect to the X server (usually on display :0) and from there you see the GUI the program's meant to display. Here's a a little flow-chart representing a regular X server:
Program > X server > Xorg > Graphics Card > Monitor
When using AIGLX or Xgl, however, they add special OpenGL (an implementation of 3D) calls to make all the fancy effects that you see like the wobbly-windows and such.
Xgl is basically re-writing the existing X server, and replacing it with one that's using these new OpenGL calls. Here's the flow-chart again:
Program > X server > Xgl > Graphics Card > Monitor
As you guessed, on one hand this is great because you get these really neat effects, but on the other isn't good at all because since it's replacing the existing X server, any future work done to it won't be done in Xgl. It won't matter how many cool new features come to Xorg, you'll never get them in Xgl because it's replacing the traditional X server. Additionally, users of Xgl will have to deal with Xgl's bugs, where as you'll see users of AIGLX don't.

AIGLX is built-in to Xorg 7.1, which ships with FC6. AIGLX is a more incremental change than Xgl, seeing as it's adapted the existing Xorg server to use the new special calls. Here's the flow-chart for AIGLX:
Program > X server > Xorg (with adapted calls) > Graphics Card > Monitor
As you can see, nothings' changed from the original chart. All that happened was developers added an extension so you can still have the excellent Xorg server and all work that's done to it in the future, but also the really cool effects. This is why AIGLX is personally my preferred path.

Beryl & Compiz
Beryl and Compiz are both window managers, that run inside a X server. They basically handle where the windows are on your screen and their borders - eg the little 'x' in the corner of the windows. Once you have Xgl or AIGLX setup, you can switch back and forth from them as you please.

Important Notes / Updates
  • If you're following this howto, I expect you to have a working graphics card with drivers installed or DRI enabled - If you don't, then please see my howtos for or cards.
  • Beryl (previously Quinnstorm) is now supported, too!
  • *** If you have a nVidia card it is _required_ to use the 1.0-9625 driver or better if you want to use AIGLX, nothing less.
  • gset-compiz isn't working so well, but what you can do instead use gconf-editor to manually edit Compiz settings. Once you install gconf-editor, open it up (Applications > System Tools > Configuration Editor), edit take a look at apps/compiz/.
  • Definitive way to get ATi cards working:
    (1) Try using AIGLX, aka with the 'radeon' driver. If you're getting "No devices found", then that means your card isn't supported by the driver.
    (2) Now if you try fglrx from Livna with Xgl, things should work out better.
    *** In other words, you can use the 'radeon' driver with AIGLX, OR the 'fglrx' driver with Xgl.
  • Finally, the fc5 versions of compiz seem to be giving people lots of headaches, for many reasons. Please don't ask for help with fc5. The answer is here: Upgrade to fc6.

- AIGLX -
AIGLX - Compiz
Code:
su -
yum update
yum install compiz
gconftool-2 -s '/apps/metacity/general/compositing_manager' --type bool true
desktop-effects


AIGLX - Beryl
Code:
su -
cd /etc/yum.repos.d/
wget
yum -y install beryl-core beryl-manager beryl-plugins beryl-settings emerald emerald-themes

Now just run:
Code:
beryl-manager

And use the Beryl tray icon from there.

Troubles with AIGLX
the defaults xorg.conf's in FC6 should work, but things don't always work as they should. Here's a few tips that have helped others:
Add these parts to your xorg.conf (/etc/X11/xorg.conf) if you don't already have it:
  • In your "Device" section:
    Code:
    Option "AddARGBGLXVisuals" "True"
    Option "DisableGLXRootClipping" "True"
  • Just have this somewhere, but not within another Section:
    Code:
    Section "DRI"
    Group 0
    Mode 0666
    EndSection
  • It seems some of the default fc6 xorg.conf's don't have a "Module" section. If you're missing one, just leave it be like that. It will load the needed modules for AIGLX by default. (This applies to the two next points)
  • And this in your Module section, if you have a Module section:
    Code:
    Load "extmod"
  • If you're using ATi, the following in your "Module" section:
    Code:
    Load "dri"

- XGL -
(1) Install the Xgl repo:
Code:

su -
rpm -Uhv


(2) Edit the /etc/yum.repos.d/fedora-xgl.repo file and change
Code:

gpgcheck=1
to
Code:
gpgcheck=0
.

(-) Fedora Core 6 / development users have an additional step: also in the /etc/yum.repos.d/fedora-xgl.repo file, change all instances of $releasever to 5. For example, this line:
Code:


becomes:
Code:



Xgl - Compiz
(3) Install the packages
Code:

rpm -e compiz 2> /dev/null
yum clean all
yum --enablerepo=fedora-xgl glitz-glx libsvg libsvg-cairo xorg-x11-server-Xgl xgl-hardware-list compiz


(4) Configure Xgl:
** The below erases any custom setting in your /etc/gdm/custom.conf... If you've setup VNC with my Server Setup howto or anything similar to do with GDM, you'll have to re-do those steps again. **
Code:
gnome-xgl-switch --enable-xgl --auto

Hit 'y' for save modifications. Save & close all open programs, because now hitting enter as the program tells you to will kill X (and therefore all program running in it).

(5) (Re)Configure GDM:
Edit the /etc/gdm/custom.conf file, and make sure you have this under the [daemon] section:
Code:

GdmXServerTimeout=60

Now's a good time to re-do any changed to GDM needed, too.

Xgl - Beryl
Please follow the same steps as the "Xgl - Compiz", and once you're done do this:
Code:
su -
cd /etc/yum.repos.d/
wget
yum -y install beryl-core beryl-manager beryl-plugins beryl-settings emerald emerald-themes

Now just run:
Code:
beryl-manager

And use the Beryl tray icon from there.

- Various fixes -

** Help! desktop-effects fails! **

Try running it from a terminal:
Code:

desktop-effects

If you see this:
Code:
compiz: No sync extension

Adding this to your "Module" section in /etc/X11/xorg.conf:
Code:
SubSection "extmod"
Option "omit xfree86-dga" # don't initialise the DGA extension
EndSubSection

It may help in some cases.

If that's not the error message you get, please post to the thread and we can try to help you out.

** Java **

I'm sure some have noticed, for example, how some OpenGL games or GUI Java apps suddenly stopped working with the upgrade to XGL / AIGLX. There is a fix - Xnest is a nested X server, which means basically you run a normal Xorg session (without fancy effects) in a window. Here's how to get apps like LimeWire working again:
(1) Install Xnest:
Code:

su -
yum install xorg-x11-server-Xnest -y
exit

(2) Start a Xnest session:
Code:

Xnest -ac :1 &
export DISPLAY=:1
metacity &

(3) Now, the result is a new, black window - The nested Xorg, and in your terminal should still be able type commands. Now, simply type the name of the application you'd like to start with a ampersand ( the "&" ) after it, and you're set. So, for example, this:
Code:

Xnest -ac :1 &
export DISPLAY=:1
metacity &
limewire &

will run LimeWire properly. Replace the "limewire &" line for let say "nexuiz &" and you guessed it, you're running Nexuiz.

- References -

Compiz keyboard shortcuts!






Firewing1
___________________________
Diffingo Solutions Inc.:
(script-wing has been moved here)
The best of my howtos:
,
,
, *Getting or cards working in FC

阅读(5850) | 评论(4) | 转发(0) |
给主人留下些什么吧!~~