个人工具

“UbuntuHelp:CompositeManager/Xgl”的版本间的差异

来自Ubuntu中文

跳转至: 导航, 搜索
(New page: {{From|https://help.ubuntu.com/community/CompositeManager/Xgl}} {{Languages|php5}} <!> Xgl is alpha software so it isn't recommended that you install this software on a production machin...)
 
 
(未显示2个用户的15个中间版本)
第1行: 第1行:
 
{{From|https://help.ubuntu.com/community/CompositeManager/Xgl}}
 
{{From|https://help.ubuntu.com/community/CompositeManager/Xgl}}
{{Languages|php5}}
+
{{Languages|UbuntuHelp:CompositeManager/Xgl}}
 
+
=== Warnings ===
 
+
<!> This guide works great for Feisty Fawn 7.04.  Do NOT follow this guide for Gutsy Gibbon 7.10 since Xgl framework has changed dramatically.
 
<!> Xgl is alpha software so it isn't recommended that you install this software on a production machine. For Dual Monitor (or more) users: A lot of people are experiencing troubles when enabling Xgl. Especially for this group, be *very* careful with Xgl.
 
<!> Xgl is alpha software so it isn't recommended that you install this software on a production machine. For Dual Monitor (or more) users: A lot of people are experiencing troubles when enabling Xgl. Especially for this group, be *very* careful with Xgl.
 
+
----------
 
+
<!> For a simpler way that should work with Gusty Gibbon and ATI Radeon and Mobility Radeon GPU's click on the following link: >[[UbuntuHelp:/simple|/simple]]<
 +
----------
 
=== Introduction ===
 
=== Introduction ===
This page details how to install Xgl on your system.
+
This page details how to install Xgl on your system.
 
+
 
==== Prerequisites ====
 
==== Prerequisites ====
  1. You need to be running at least the Dapper (6.06 LTS) release.
+
<ol><li>You need to be running at least the Dapper (6.06 LTS) release.
  2. You need a supported video card. (See list below.)
+
</li><li>You need a supported video card. (See list below.)
  3. You need to have video card drivers with 3D acceleration installed. See [https://help.ubuntu.com/ubuntu/desktopguide/C/hardware.html Hardware] on the Ubuntu Documentation for help with this.
+
</li><li>You need to have video card drivers with 3D acceleration installed. See [https://help.ubuntu.com/ubuntu/desktopguide/C/hardware.html Hardware] on the Ubuntu Documentation for help with this.</li></ol>
  
 
==== Supported Hardware ====
 
==== Supported Hardware ====
** '''ATI'''
+
* '''ATI'''
*** Mobility Radeon 9700 SE: Xgl running with proprietary fglrx driver 8.23
+
* Mobility Radeon 9700 SE: Xgl running with proprietary fglrx driver 8.23
*** Radeon X300: Xgl running with proprietary fglrx driver 8.23
+
* Radeon X300: Xgl running with proprietary fglrx driver 8.23
** '''NVIDIA'''
+
* '''NVIDIA'''
*** A MX 4xxx series card or newer using the NVIDIA binary driver.
+
* A MX 4xxx series card or newer using the NVIDIA binary driver.
** '''Intel'''
+
* '''Intel'''
*** i8xx and i9xx
+
* i8xx and i9xx
 
+
 
(./) For a comprehensive list of supported graphics cards with user comments, see this [http://gentoo-wiki.com/HARDWARE_Video_Card_Support_Under_XGL Gentoo Wiki page].
 
(./) For a comprehensive list of supported graphics cards with user comments, see this [http://gentoo-wiki.com/HARDWARE_Video_Card_Support_Under_XGL Gentoo Wiki page].
 
 
(!) Note for intel users : Running xgl might be slow with intel cards. If you want to run compiz, you might prefer to run aiglx.
 
(!) Note for intel users : Running xgl might be slow with intel cards. If you want to run compiz, you might prefer to run aiglx.
 
 
=== Installation ===
 
=== Installation ===
 
 
==== Installing Xgl packages ====
 
==== Installing Xgl packages ====
 
+
All you have to do is install the '''xserver-xgl''' package, it will take care of all the dependencies. See [https://help.ubuntu.com/ubuntu/desktopguide/C/add-applications.html Adding, Removing and Updating Applications] for help with this.
All you have to do is install the '''xserver-xgl''' package, it will take care of all the dependencies. See [https://help.ubuntu.com/ubuntu/desktopguide/C/add-applications.html Adding, Removing and Updating Applications] for help with this.
+
 
+
 
<pre><nowiki>
 
<pre><nowiki>
 
sudo apt-get install xserver-xgl
 
sudo apt-get install xserver-xgl
 
</nowiki></pre>
 
</nowiki></pre>
 
+
For Gutsy (Ubuntu 7.10) users this is all you need to do.  Once installed, Gutsy's Xgl will automatically start next time you log in.  Users of Feisty (Ubuntu 7.04) and older will need to do the further set up described on the rest of this page.
 
+
=== Choose How Your Computer Will Start Xgl (Feisty and older) ===
=== Choose How Your Computer Will Start Xgl ===
+
There are multiple ways to run Xgl. You may first want to test everything works before making Xgl and compiz your default configuration. One way to do this is to run Xgl as part of your desktop session. Short of a hard lock, you can terminate that session to stop Xgl and continue using the regular X server. Method A below describes this route.
 
+
Method B is about setting Xgl as the standard X server started by GDM, the Gnome Display Manager. This is basically system-wide deployment of Xgl rather than per user desktop session.
There are multiple ways to run Xgl. You may first want to test everything works before making Xgl and compiz your default configuration. One way to do this is to run Xgl as part of your desktop session. Short of a hard lock, you can terminate that session to stop Xgl and continue using the regular X server. Method A below describes this route.
+
(!) KDE and XFCE Users should use method A, GNOME users may choose either.
+
<<BR>>
Method B is about setting Xgl as the standard X server started by GDM, the Gnome Display Manager. This is basically system-wide deployment of Xgl rather than per user desktop session.
+
 
+
(!) KDE and XFCE Users should use method A, GNOME users may choose either.
+
 
+
<br>
+
 
==== Method A: Xgl Session on Login Window ====
 
==== Method A: Xgl Session on Login Window ====
 
+
This will allow you to start Xgl as an option at the login screen. The Xgl server starts on DISPLAY :1 as part of your desktop session and terminates when you end your session. This is convenient route as you can simply select a regular session if Xgl doesn't work. Xorg continues running on DISPLAY :0 since it's needed by Xgl.
This will allow you to start Xgl as an option at the login screen. The Xgl server starts on DISPLAY :1 as part of your desktop session and terminates when you end your session. This is convenient route as you can simply select a regular session if Xgl doesn't work. Xorg continues running on DISPLAY :0 since it's needed by Xgl.
+
* We will need to create two new files: a startup script and a X session file.  
 
+
Open up a terminal and create a new script named startxgl.sh:
** We will need to create two new files: a startup script and a X session file.  
+
<pre><nowiki>
 
+
Open up a terminal and create a new script named startxgl.sh:
+
  <pre><nowiki>
+
 
gksudo gedit /usr/bin/startxgl.sh</nowiki></pre>
 
gksudo gedit /usr/bin/startxgl.sh</nowiki></pre>
 
+
On Kubuntu run:
(!) Note that <code><nowiki>/usr/bin</nowiki></code> is the place where most of the system's binaries get installed; <code><nowiki>/usr/local/bin</nowiki></code> or <code><nowiki>~/bin</nowiki></code> are usually regarded as better places for locally installed and administered software. If you decide to create your script in one of these places be aware that you may need to create the directories as well. Don't forget to change the script's location accordingly throughout the tutorial.
+
<pre><nowiki>
 
+
kdesu kate /usr/bin/startxgl.sh</nowiki></pre>
 
+
(!) Note that <code><nowiki>/usr/bin</nowiki></code> is the place where most of the system's binaries get installed; <code><nowiki>/usr/local/bin</nowiki></code> or <code><nowiki>~/bin</nowiki></code> are usually regarded as better places for locally installed and administered software. If you decide to create your script in one of these places be aware that you may need to create the directories as well. Don't forget to change the script's location accordingly throughout the tutorial.
 
+
{|border="1" cellspacing="0"
||<tablestyle="font-size: 0.9em; width:95%; background:#cccccc; margin: 0 0 1em 1em; padding:1.5em; text-align:center"> '''NVIDIA (using GNOME)''' ||<style="width: 65%; text-align: left"> #!/bin/sh <br>Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &<br>DISPLAY=:1<br>dbus-launch --exit-with-session gnome-session ||
+
| '''NVIDIA (using GNOME)''' || #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &>DISPLAY=:1>dbus-launch --exit-with-session gnome-session  
||<rowbgcolor="#dee3e7"> '''NVIDIA (using KDE)''' ||<(> #!/bin/sh <br>Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &<br>DISPLAY=:1<br>exec startkde ||
+
|-
|| '''NVIDIA (using XFCE)''' ||<(> #!/bin/sh <br>Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &<br>DISPLAY=:1<br>exec xfce4-session ||
+
| '''NVIDIA (using KDE)''' || #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &>DISPLAY=:1>exec startkde  
||<rowbgcolor="#b3c57c"> '''ATI and Intel (using GNOME)''' ||<(> #!/bin/sh <br>Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &<br>DISPLAY=:1<br>dbus-launch --exit-with-session gnome-session ||
+
|-
||<rowbgcolor="#cdd9a8"> '''ATI and Intel (using KDE)''' ||<(> #!/bin/sh <br>Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &<br>DISPLAY=:1<br>exec startkde ||
+
| '''NVIDIA (using XFCE)''' || #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &>DISPLAY=:1>exec xfce4-session  
||<rowbgcolor="#b3c57c"> '''ATI and Intel (using XFCE)''' ||<(> #!/bin/sh <br>Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &<br>DISPLAY=:1<br>exec xfce4-session ||
+
|-
 
+
| '''ATI or Intel (using GNOME)''' || #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &>DISPLAY=:1>dbus-launch --exit-with-session gnome-session  
** Save this file, and close the editor.
+
|-
 
+
| '''ATI or Intel (using KDE)''' || #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &>DISPLAY=:1>exec startkde  
** Make the script executable with the following command:
+
|-
    <pre><nowiki>
+
| '''ATI or Intel (using XFCE)''' || #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &>DISPLAY=:1>exec xfce4-session  
 +
|}
 +
(!) The package dbus-x11 is needed for the dbus-launch command. If it is not installed your xsession will terminate on launch.
 +
* Save this file, and close the editor.
 +
* Make the script executable with the following command:
 +
<pre><nowiki>
 
sudo chmod +x /usr/bin/startxgl.sh</nowiki></pre>
 
sudo chmod +x /usr/bin/startxgl.sh</nowiki></pre>
 
+
* Now we'll add an option to the gnome login manager so that we can choose to log into our new Xgl-gnome session. Create an Xsession file like so:
** Now we'll add an option to the gnome login manager so that we can choose to log into our new Xgl-gnome session. Create an Xsession file like so:
+
<pre><nowiki>
    <pre><nowiki>
+
 
gksudo gedit /usr/share/xsessions/xgl.desktop</nowiki></pre>
 
gksudo gedit /usr/share/xsessions/xgl.desktop</nowiki></pre>
 
+
In Kubuntu run
** In this file, paste the following:
+
<pre><nowiki>
    <pre><nowiki>
+
kdesu kate /usr/share/xsessions/xgl.desktop</nowiki></pre>
 +
* In this file, paste the following:
 +
<pre><nowiki>
 
[Desktop Entry]
 
[Desktop Entry]
 
Encoding=UTF-8
 
Encoding=UTF-8
第87行: 第79行:
 
Icon=
 
Icon=
 
Type=Application</nowiki></pre>
 
Type=Application</nowiki></pre>
 
+
* Save this file and close the editor.
** Save this file and close the editor.
+
* To log into Xgl, logout of your current session, and from the login screen click "Options" and "Session chooser".
+
* Select "Xgl" from the Session menu.
** To log into Xgl, logout of your current session, and from the login screen click "Options" and "Session chooser".
+
* When you login, gdm will ask if you would like to make the "Xgl" session the default session. For now, choose "Just for this session".
 
+
(!) When your Xgl desktop appears for the first time, gnome may ask you about your keyboard localization preference. Choose "Use Gnome keyboard localization" to continue using your usual keyboard settings.
** Select "Xgl" from the Session menu.
+
 
+
** When you login, gdm will ask if you would like to make the "Xgl" session the default session. For now, choose "Just for this session".
+
 
+
(!) When your Xgl desktop appears for the first time, gnome may ask you about your keyboard localization preference. Choose "Use Gnome keyboard localization" to continue using your usual keyboard settings.
+
 
+
 
----
 
----
 
+
<<BR>>
<br>
+
 
==== Method B: Make Xgl Your Standard Display Server for Ubuntu Users ====
 
==== Method B: Make Xgl Your Standard Display Server for Ubuntu Users ====
Another way to run Xgl involves replacing Xorg with Xgl as the standard X display server for use with GDM, the Gnome Display Manager. Xgl will take DISPLAY :0 and start Xorg on DISPLAY :93 since it's needed by Xgl. Switching between X servers will not be as simple as logging out and back in again though; it will require a little bit of file editing instead.
+
Another way to run Xgl involves replacing Xorg with Xgl as the standard X display server for use with GDM, the Gnome Display Manager. Xgl will take DISPLAY :0 and start Xorg on DISPLAY :93 since it's needed by Xgl. Switching between X servers will not be as simple as logging out and back in again though; it will require a little bit of file editing instead.
 
+
 
+
 
===== If you have NVIDIA =====
 
===== If you have NVIDIA =====
 
+
We'll configure the gnome display manager. In the terminal type:
We'll configure the gnome display manager. In the terminal type:
+
<pre><nowiki>
  <pre><nowiki>
+
 
gksudo gedit /etc/gdm/gdm.conf-custom</nowiki></pre>
 
gksudo gedit /etc/gdm/gdm.conf-custom</nowiki></pre>
 
+
Find the [servers] section and modify it to look like this:
Find the [servers] section and modify it to look like this:
+
<pre><nowiki>
  <pre><nowiki>
+
 
[servers]
 
[servers]
 
0=Xgl
 
0=Xgl
第120行: 第101行:
 
command=/usr/bin/Xgl -fullscreen -br -accel xv:fbo -accel glx:pbuffer
 
command=/usr/bin/Xgl -fullscreen -br -accel xv:fbo -accel glx:pbuffer
 
flexible=true</nowiki></pre>
 
flexible=true</nowiki></pre>
 
 
 
 
===== If you have ATI with fglrx drivers =====
 
===== If you have ATI with fglrx drivers =====
 
+
When we use this alternative we must change standard server to 1
When we use this alternative we must change standard server to 1
+
<pre><nowiki>
  <pre><nowiki>
+
 
gksudo gedit /etc/gdm/gdm.conf</nowiki></pre>
 
gksudo gedit /etc/gdm/gdm.conf</nowiki></pre>
Find this lines and switch standard server to 1
+
Find this lines and switch standard server to 1
  <pre><nowiki>
+
<pre><nowiki>
 
#0=Standard
 
#0=Standard
 
1=Standard</nowiki></pre>
 
1=Standard</nowiki></pre>
 
+
Now we configure a custom display server:
Now we configure a custom display server:
+
<pre><nowiki>
  <pre><nowiki>
+
 
gksudo gedit /etc/gdm/gdm.conf-custom</nowiki></pre>
 
gksudo gedit /etc/gdm/gdm.conf-custom</nowiki></pre>
 
 
Add a new [server-Xgl] section and change the [servers] section to look like this:
 
Add a new [server-Xgl] section and change the [servers] section to look like this:
  <pre><nowiki>
+
<pre><nowiki>
 
[servers]
 
[servers]
 
1=Xgl #Override display 1 to use Xgl (DISPLAY 1 IMPORTANT FOR FGLRX, 0 works on Edgy+FGLRX).   
 
1=Xgl #Override display 1 to use Xgl (DISPLAY 1 IMPORTANT FOR FGLRX, 0 works on Edgy+FGLRX).   
第146行: 第121行:
 
command=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer -dpi 100 -nolisten tcp
 
command=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer -dpi 100 -nolisten tcp
 
flexible=true</nowiki></pre>
 
flexible=true</nowiki></pre>
 
 
 
===== Else =====
 
===== Else =====
 
+
Add a new [server-Xgl] section and change the [servers] section to look like this:
Add a new [server-Xgl] section and change the [servers] section to look like this:
+
<pre><nowiki>
  <pre><nowiki>
+
 
[servers]
 
[servers]
 
0=Xgl
 
0=Xgl
第159行: 第131行:
 
command=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer
 
command=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer
 
flexible=true</nowiki></pre>
 
flexible=true</nowiki></pre>
 
 
----
 
----
 
 
(!) If you have ATI with the ati drivers then display is 0 and not 1 as with the fglrx drivers. To find out what drivers you are using type <code><nowiki>grep "Driver" /etc/X11/xorg.conf</nowiki></code> in a terminal and look for "ati" or "fglrx". Display 0 may work with the FGLRX driver under Edgy Eft/6.10.
 
(!) If you have ATI with the ati drivers then display is 0 and not 1 as with the fglrx drivers. To find out what drivers you are using type <code><nowiki>grep "Driver" /etc/X11/xorg.conf</nowiki></code> in a terminal and look for "ati" or "fglrx". Display 0 may work with the FGLRX driver under Edgy Eft/6.10.
 
 
(!) Xgl server takes a bit longer to start up than normal X server. If you are not able to reach the login screen and you notice that the Xgl server tries to start up multiple times before falling back to console login, you may try editing the file <code><nowiki>/etc/gdm/gdm.conf</nowiki></code> and changing the line <code><nowiki>GdmXserverTimeout=10</nowiki></code> into <code><nowiki>GdmXserverTimeout=50</nowiki></code> -- Battlehorse
 
(!) Xgl server takes a bit longer to start up than normal X server. If you are not able to reach the login screen and you notice that the Xgl server tries to start up multiple times before falling back to console login, you may try editing the file <code><nowiki>/etc/gdm/gdm.conf</nowiki></code> and changing the line <code><nowiki>GdmXserverTimeout=10</nowiki></code> into <code><nowiki>GdmXserverTimeout=50</nowiki></code> -- Battlehorse
 
 
(!) To make sure Xgl is running in your current session, just run <code><nowiki>ps -e | grep Xgl</nowiki></code> from a terminal.  If there is output it is running, if not you have a configuration issue and should seek assistance.
 
(!) To make sure Xgl is running in your current session, just run <code><nowiki>ps -e | grep Xgl</nowiki></code> from a terminal.  If there is output it is running, if not you have a configuration issue and should seek assistance.
 
 
(!) If you are using an ATI card with method B, you may end up with the ATI driver unable to find the card during XGL startup. You will know if this is the case if animations are slow when opening or moving a program window. This has been verified on a Dell Optiplex GX620 with a Radeon X600. If this occurs, you can attempt to use display 0 instead of display 1 in the gdm-conf.custom file.
 
(!) If you are using an ATI card with method B, you may end up with the ATI driver unable to find the card during XGL startup. You will know if this is the case if animations are slow when opening or moving a program window. This has been verified on a Dell Optiplex GX620 with a Radeon X600. If this occurs, you can attempt to use display 0 instead of display 1 in the gdm-conf.custom file.
 
+
(!) If you are using an ATI card with fglrx drivers, your dpi is set to non-default 100 and your fonts will look fuzzy.  After you complete this guide and start Gnome, select <code><nowiki>System/Preferences/Fonts</nowiki></code>, click on <code><nowiki>Details</nowiki></code>, and adjust <code><nowiki>Resolution</nowiki></code> to '''100''' dots per inch. 
 
+
<<BR>>
 
+
<br>
+
 
==== Method C: Make Xgl Your Standard Display Server for Kubuntu Users ====
 
==== Method C: Make Xgl Your Standard Display Server for Kubuntu Users ====
 
+
Yet again, another way to run Xgl involves replacing Xorg with Xgl as the standard X display server for use with KDM, the KDE Display Manager. Xgl will take DISPLAY :0 and start Xorg on DISPLAY :93 since it's needed by Xgl. Switching between X servers will not be as simple as logging out and back in again though; it will require a little bit of file editing instead.
Yet again, another way to run Xgl involves replacing Xorg with Xgl as the standard X display server for use with KDM, the KDE Display Manager. Xgl will take DISPLAY :0 and start Xorg on DISPLAY :93 since it's needed by Xgl. Switching between X servers will not be as simple as logging out and back in again though; it will require a little bit of file editing instead.
+
 
+
 
(!) You should be warned, this method has been reported to be unstable on several configurations with no real cause.  If this is the case for you you should try Method A instead.
 
(!) You should be warned, this method has been reported to be unstable on several configurations with no real cause.  If this is the case for you you should try Method A instead.
 
+
We'll configure the KDE display manager. In the terminal type:
We'll configure the KDE display manager. In the terminal type:
+
<pre><nowiki>
  <pre><nowiki>
+
 
kdesu kate /etc/kde3/kdm/kdmrc</nowiki></pre>
 
kdesu kate /etc/kde3/kdm/kdmrc</nowiki></pre>
 
 
===== If you have NVIDIA =====
 
===== If you have NVIDIA =====
 
+
We need to edit the ServerCmd line to look like this:
We need to edit the ServerCmd line to look like this:
+
<pre><nowiki>
  <pre><nowiki>
+
 
ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:fbo -accel glx:pbuffer
 
ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:fbo -accel glx:pbuffer
 
</nowiki></pre>
 
</nowiki></pre>
 
 
 
===== If you have ATI =====
 
===== If you have ATI =====
 
+
We need to edit the ServerCmd line to look like this:
We need to edit the ServerCmd line to look like this:
+
<pre><nowiki>
  <pre><nowiki>
+
 
ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer
 
ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer
 
</nowiki></pre>
 
</nowiki></pre>
 
 
 
===== Else =====
 
===== Else =====
 
+
We need to edit the ServerCmd line to look like this:
We need to edit the ServerCmd line to look like this:
+
<pre><nowiki>
  <pre><nowiki>
+
 
ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer
 
ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer
 
</nowiki></pre>
 
</nowiki></pre>
 
 
You will need to restart KDM before the changes take place.  If X does not come back up, revert your kdmrc.
 
You will need to restart KDM before the changes take place.  If X does not come back up, revert your kdmrc.
 
+
<<BR>>
 
+
<br>
+
 
=== Xgl Installed! ===
 
=== Xgl Installed! ===
 
+
Let's move on to installing a [[UbuntuHelp:CompositeManager#head-b10b0a671d1bdc5e1958d3c614c9a9d0a8045efa|composite|manager]]!
Let's move on to installing a [https://help.ubuntu.com/community/CompositeManager#head-b10b0a671d1bdc5e1958d3c614c9a9d0a8045efa composite manager]!
+
==== Further reading ====
http://www.google.nl/
+
* [http://en.opensuse.org/Xgl OpenSuse Xgl]
<br>
+
* [http://en.wikipedia.org/wiki/Xgl Wikipedia Xgl]
 +
* [http://www.freedesktop.org/wiki/Software/Xgl Freedesktop Xgl]
 +
<<BR>>
 
=== Discussion ===
 
=== Discussion ===
 
 
* MatteoZandi, I choosed method A, but when I log out there is no shutdown button, how comes? How should I fix it?
 
* MatteoZandi, I choosed method A, but when I log out there is no shutdown button, how comes? How should I fix it?
 
+
see also thread http://www.ubuntuforums.org/showthread.php?t=206122&highlight=xgl+shutdown
see also thread http://www.ubuntuforums.org/showthread.php?t=206122&highlight=xgl+shutdown
+
 
+
 
----
 
----
 
 
* AlwinGarside: I can't get Xgl to start using method A no matter what I try. I think it should be documented better.
 
* AlwinGarside: I can't get Xgl to start using method A no matter what I try. I think it should be documented better.
 
 
----
 
----
 
 
* NicholasIstre: Also, method A currently has an issue where the screen will black out if no input has been entered in around 10 minutes, despite any settings in the screensaver and power management.  This is an issue when watching movies that are longer than 10 minutes.  Method B doesn't have this problem.
 
* NicholasIstre: Also, method A currently has an issue where the screen will black out if no input has been entered in around 10 minutes, despite any settings in the screensaver and power management.  This is an issue when watching movies that are longer than 10 minutes.  Method B doesn't have this problem.
 
 
----
 
----
 
 
* Focher: Can someone add a method for checking to see if Xgl is running?
 
* Focher: Can someone add a method for checking to see if Xgl is running?
 
+
Open System > Administration > System Monitor, then look for Xgl as a running process.
Open System > Administration > System Monitor, then look for Xgl as a running process.
+
 
+
 
----
 
----
 
 
*casper911ca : Xgl is running terribly slow. I've gone though this TWICE and it each time i get the same result. Nvidia Quadro FX Go1400. I sucessfully set Xgl/compiz in FC5 and it ran beautifully, so I know its possible.  
 
*casper911ca : Xgl is running terribly slow. I've gone though this TWICE and it each time i get the same result. Nvidia Quadro FX Go1400. I sucessfully set Xgl/compiz in FC5 and it ran beautifully, so I know its possible.  
  :~$ glxgears
+
:~$ glxgears
  85357 frames in 5.0 seconds = 17071.295 FPS
+
85357 frames in 5.0 seconds = 17071.295 FPS
  95417 frames in 5.0 seconds = 19083.328 FPS
+
95417 frames in 5.0 seconds = 19083.328 FPS
 
+
 
----
 
----
 
 
*Fafek2: Does anybody know how to install Xgl on Matrox G450 card with Ubuntu 6.06? Open source drivers "mga" are already installed and they support direct rendering.
 
*Fafek2: Does anybody know how to install Xgl on Matrox G450 card with Ubuntu 6.06? Open source drivers "mga" are already installed and they support direct rendering.
 
 
----
 
----
 
 
* Angrykeyboarder : What if I run both KDE and GNOME and wish to enable XGL on both?  And can this be done with KDM vs. GDM?  Also, are the existing instructions any different for Edgy?
 
* Angrykeyboarder : What if I run both KDE and GNOME and wish to enable XGL on both?  And can this be done with KDM vs. GDM?  Also, are the existing instructions any different for Edgy?
 
 
----
 
----
 
 
* GianlucaDAndrea : i've an ati x600 video card on a toshiba satellite m50 running dapper. the method A works perfectly, while the method B don't works, even if I use 0=Xgl in /etc/gdm/gdm.conf-custom. what's the problem?
 
* GianlucaDAndrea : i've an ati x600 video card on a toshiba satellite m50 running dapper. the method A works perfectly, while the method B don't works, even if I use 0=Xgl in /etc/gdm/gdm.conf-custom. what's the problem?
 
 
----
 
----
 
 
* GianlucaDAndrea : solved upgrading xorg 7.0 from dapper to xorg 7.1 from edgy, and installing xgl (with dependencies) from "deb http://ubuntu.beryl-project.org/ edgy main-edgy" and beryl (with dependencies) from "deb http://ubuntu.beryl-project.org/ dapper main". now xgl & beryl works with method A and method B
 
* GianlucaDAndrea : solved upgrading xorg 7.0 from dapper to xorg 7.1 from edgy, and installing xgl (with dependencies) from "deb http://ubuntu.beryl-project.org/ edgy main-edgy" and beryl (with dependencies) from "deb http://ubuntu.beryl-project.org/ dapper main". now xgl & beryl works with method A and method B
 
 
----
 
----
 
+
* [[UbuntuHelp:DavidWenRiccardiZhu|DavidWenRiccardiZhu]] : XGL through method A worked on both GNOME and KDE. However XGL on KDE runs much more slowly. Moving windows, icons, and the selected items highlight in menus all have a short delay. Any known cause(s) and possible solution(s)?
CategoryDocumentation
+
----
 +
[[category:CategoryDocumentation]]
  
 
[[category:UbuntuHelp]]
 
[[category:UbuntuHelp]]

2008年10月19日 (日) 22:23的最新版本

Warnings

<!> This guide works great for Feisty Fawn 7.04. Do NOT follow this guide for Gutsy Gibbon 7.10 since Xgl framework has changed dramatically. <!> Xgl is alpha software so it isn't recommended that you install this software on a production machine. For Dual Monitor (or more) users: A lot of people are experiencing troubles when enabling Xgl. Especially for this group, be *very* careful with Xgl.


<!> For a simpler way that should work with Gusty Gibbon and ATI Radeon and Mobility Radeon GPU's click on the following link: >/simple<


Introduction

This page details how to install Xgl on your system.

Prerequisites

  1. You need to be running at least the Dapper (6.06 LTS) release.
  2. You need a supported video card. (See list below.)
  3. You need to have video card drivers with 3D acceleration installed. See Hardware on the Ubuntu Documentation for help with this.

Supported Hardware

  • ATI
  • Mobility Radeon 9700 SE: Xgl running with proprietary fglrx driver 8.23
  • Radeon X300: Xgl running with proprietary fglrx driver 8.23
  • NVIDIA
  • A MX 4xxx series card or newer using the NVIDIA binary driver.
  • Intel
  • i8xx and i9xx

(./) For a comprehensive list of supported graphics cards with user comments, see this Gentoo Wiki page. (!) Note for intel users : Running xgl might be slow with intel cards. If you want to run compiz, you might prefer to run aiglx.

Installation

Installing Xgl packages

All you have to do is install the xserver-xgl package, it will take care of all the dependencies. See Adding, Removing and Updating Applications for help with this.

sudo apt-get install xserver-xgl

For Gutsy (Ubuntu 7.10) users this is all you need to do. Once installed, Gutsy's Xgl will automatically start next time you log in. Users of Feisty (Ubuntu 7.04) and older will need to do the further set up described on the rest of this page.

Choose How Your Computer Will Start Xgl (Feisty and older)

There are multiple ways to run Xgl. You may first want to test everything works before making Xgl and compiz your default configuration. One way to do this is to run Xgl as part of your desktop session. Short of a hard lock, you can terminate that session to stop Xgl and continue using the regular X server. Method A below describes this route. Method B is about setting Xgl as the standard X server started by GDM, the Gnome Display Manager. This is basically system-wide deployment of Xgl rather than per user desktop session. (!) KDE and XFCE Users should use method A, GNOME users may choose either. <
>

Method A: Xgl Session on Login Window

This will allow you to start Xgl as an option at the login screen. The Xgl server starts on DISPLAY :1 as part of your desktop session and terminates when you end your session. This is convenient route as you can simply select a regular session if Xgl doesn't work. Xorg continues running on DISPLAY :0 since it's needed by Xgl.

  • We will need to create two new files: a startup script and a X session file.

Open up a terminal and create a new script named startxgl.sh:

gksudo gedit /usr/bin/startxgl.sh

On Kubuntu run:

kdesu kate /usr/bin/startxgl.sh

(!) Note that /usr/bin is the place where most of the system's binaries get installed; /usr/local/bin or ~/bin are usually regarded as better places for locally installed and administered software. If you decide to create your script in one of these places be aware that you may need to create the directories as well. Don't forget to change the script's location accordingly throughout the tutorial.

NVIDIA (using GNOME) #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &>DISPLAY=:1>dbus-launch --exit-with-session gnome-session
NVIDIA (using KDE) #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &>DISPLAY=:1>exec startkde
NVIDIA (using XFCE) #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:fbo -accel glx:pbuffer &>DISPLAY=:1>exec xfce4-session
ATI or Intel (using GNOME) #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &>DISPLAY=:1>dbus-launch --exit-with-session gnome-session
ATI or Intel (using KDE) #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &>DISPLAY=:1>exec startkde
ATI or Intel (using XFCE) #!/bin/sh >Xgl :1 -fullscreen -ac -accel xv:pbuffer -accel glx:pbuffer &>DISPLAY=:1>exec xfce4-session

(!) The package dbus-x11 is needed for the dbus-launch command. If it is not installed your xsession will terminate on launch.

  • Save this file, and close the editor.
  • Make the script executable with the following command:
sudo chmod +x /usr/bin/startxgl.sh
  • Now we'll add an option to the gnome login manager so that we can choose to log into our new Xgl-gnome session. Create an Xsession file like so:
gksudo gedit /usr/share/xsessions/xgl.desktop

In Kubuntu run

kdesu kate /usr/share/xsessions/xgl.desktop
  • In this file, paste the following:
[Desktop Entry]
Encoding=UTF-8
Name=Xgl
Comment=Start an Xgl Session
Exec=/usr/bin/startxgl.sh
Icon=
Type=Application
  • Save this file and close the editor.
  • To log into Xgl, logout of your current session, and from the login screen click "Options" and "Session chooser".
  • Select "Xgl" from the Session menu.
  • When you login, gdm will ask if you would like to make the "Xgl" session the default session. For now, choose "Just for this session".

(!) When your Xgl desktop appears for the first time, gnome may ask you about your keyboard localization preference. Choose "Use Gnome keyboard localization" to continue using your usual keyboard settings.


<
>

Method B: Make Xgl Your Standard Display Server for Ubuntu Users

Another way to run Xgl involves replacing Xorg with Xgl as the standard X display server for use with GDM, the Gnome Display Manager. Xgl will take DISPLAY :0 and start Xorg on DISPLAY :93 since it's needed by Xgl. Switching between X servers will not be as simple as logging out and back in again though; it will require a little bit of file editing instead.

If you have NVIDIA

We'll configure the gnome display manager. In the terminal type:

gksudo gedit /etc/gdm/gdm.conf-custom

Find the [servers] section and modify it to look like this:

[servers]
0=Xgl

[server-Xgl] 
name=Xgl server 
command=/usr/bin/Xgl -fullscreen -br -accel xv:fbo -accel glx:pbuffer
flexible=true
If you have ATI with fglrx drivers

When we use this alternative we must change standard server to 1

gksudo gedit /etc/gdm/gdm.conf

Find this lines and switch standard server to 1

#0=Standard
1=Standard

Now we configure a custom display server:

gksudo gedit /etc/gdm/gdm.conf-custom

Add a new [server-Xgl] section and change the [servers] section to look like this:

[servers]
1=Xgl #Override display 1 to use Xgl (DISPLAY 1 IMPORTANT FOR FGLRX, 0 works on Edgy+FGLRX).  

[server-Xgl] 
name=Xgl server
command=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer -dpi 100 -nolisten tcp
flexible=true
Else

Add a new [server-Xgl] section and change the [servers] section to look like this:

[servers]
0=Xgl

[server-Xgl] 
name=Xgl server 
command=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer
flexible=true

(!) If you have ATI with the ati drivers then display is 0 and not 1 as with the fglrx drivers. To find out what drivers you are using type grep "Driver" /etc/X11/xorg.conf in a terminal and look for "ati" or "fglrx". Display 0 may work with the FGLRX driver under Edgy Eft/6.10. (!) Xgl server takes a bit longer to start up than normal X server. If you are not able to reach the login screen and you notice that the Xgl server tries to start up multiple times before falling back to console login, you may try editing the file /etc/gdm/gdm.conf and changing the line GdmXserverTimeout=10 into GdmXserverTimeout=50 -- Battlehorse (!) To make sure Xgl is running in your current session, just run ps -e | grep Xgl from a terminal. If there is output it is running, if not you have a configuration issue and should seek assistance. (!) If you are using an ATI card with method B, you may end up with the ATI driver unable to find the card during XGL startup. You will know if this is the case if animations are slow when opening or moving a program window. This has been verified on a Dell Optiplex GX620 with a Radeon X600. If this occurs, you can attempt to use display 0 instead of display 1 in the gdm-conf.custom file. (!) If you are using an ATI card with fglrx drivers, your dpi is set to non-default 100 and your fonts will look fuzzy. After you complete this guide and start Gnome, select System/Preferences/Fonts, click on Details, and adjust Resolution to 100 dots per inch. <
>

Method C: Make Xgl Your Standard Display Server for Kubuntu Users

Yet again, another way to run Xgl involves replacing Xorg with Xgl as the standard X display server for use with KDM, the KDE Display Manager. Xgl will take DISPLAY :0 and start Xorg on DISPLAY :93 since it's needed by Xgl. Switching between X servers will not be as simple as logging out and back in again though; it will require a little bit of file editing instead. (!) You should be warned, this method has been reported to be unstable on several configurations with no real cause. If this is the case for you you should try Method A instead. We'll configure the KDE display manager. In the terminal type:

kdesu kate /etc/kde3/kdm/kdmrc
If you have NVIDIA

We need to edit the ServerCmd line to look like this:

ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:fbo -accel glx:pbuffer
If you have ATI

We need to edit the ServerCmd line to look like this:

ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer
Else

We need to edit the ServerCmd line to look like this:

ServerCmd=/usr/bin/Xgl -fullscreen -br -accel xv:pbuffer -accel glx:pbuffer

You will need to restart KDM before the changes take place. If X does not come back up, revert your kdmrc. <
>

Xgl Installed!

Let's move on to installing a composite|manager!

Further reading

<
>

Discussion

  • MatteoZandi, I choosed method A, but when I log out there is no shutdown button, how comes? How should I fix it?

see also thread http://www.ubuntuforums.org/showthread.php?t=206122&highlight=xgl+shutdown


  • AlwinGarside: I can't get Xgl to start using method A no matter what I try. I think it should be documented better.

  • NicholasIstre: Also, method A currently has an issue where the screen will black out if no input has been entered in around 10 minutes, despite any settings in the screensaver and power management. This is an issue when watching movies that are longer than 10 minutes. Method B doesn't have this problem.

  • Focher: Can someone add a method for checking to see if Xgl is running?

Open System > Administration > System Monitor, then look for Xgl as a running process.


  • casper911ca : Xgl is running terribly slow. I've gone though this TWICE and it each time i get the same result. Nvidia Quadro FX Go1400. I sucessfully set Xgl/compiz in FC5 and it ran beautifully, so I know its possible.
~$ glxgears

85357 frames in 5.0 seconds = 17071.295 FPS 95417 frames in 5.0 seconds = 19083.328 FPS


  • Fafek2: Does anybody know how to install Xgl on Matrox G450 card with Ubuntu 6.06? Open source drivers "mga" are already installed and they support direct rendering.

  • Angrykeyboarder : What if I run both KDE and GNOME and wish to enable XGL on both? And can this be done with KDM vs. GDM? Also, are the existing instructions any different for Edgy?

  • GianlucaDAndrea : i've an ati x600 video card on a toshiba satellite m50 running dapper. the method A works perfectly, while the method B don't works, even if I use 0=Xgl in /etc/gdm/gdm.conf-custom. what's the problem?


  • DavidWenRiccardiZhu : XGL through method A worked on both GNOME and KDE. However XGL on KDE runs much more slowly. Moving windows, icons, and the selected items highlight in menus all have a short delay. Any known cause(s) and possible solution(s)?