Začínáme s Vývojářskou verzí Projektu Looking Glass

Vítejte v Projektu Looking Glass!

Tento dokument je určen k rychlému zprovoznění a seznámení se s Vývojářskou verzí Projektu Looking Glass.

Aby jste mohli začít, nejprve je třeba natavit prostředí vašeho systému. Poté co ověříte, že vaše systémové prostředí je správně nastaveno, můžete stáhnout a nainstalovat Projekt Looking Glass.

1. Požadavky na platformu Hardwarové a softwarové požadavky
2. Nastavení prostředí pro Projekt Looking Glass Stažení a nainstalování potřebných komponent
3. Nainstalování Vývojářské verze Projektu Looking Glass
4. Spouštění Projektu Looking Glass Jak spustit desktop session Projektu Looking Glass
5. Když si nevíte rady
6. Zůstaňte informováni o Projektu Looking Glass Jak zůstat v kontaktu!
7. Několik slov na závěr

1. Požadavky na platformu

Před tím než začnete nastavovat vývojové prostředí pro Projekt Looking Glass, zkontrolujte prosím nejprve, zda váš systém splňuje následující minimální požadavky:

Komponenta Platforma Linux
Operační systém Většina moderních linuxových distribucí by měla fungovat, avšak setkali jsme se s určitými problémy při běhu na instalacích javy založených na portage. Předpokládáme následování této příručky pro nainstalování všech komponent ručně namísto použití portage.
CPU 2 GHz nebo rychlejší doporučeno
RAM 512MB
Grafická karta*
3D akcelerovaná grafická karta s ovladačem podporujícím OpenGL verze 1.2 nebo vyšší.
DŮLEŽITÉ! Je vyžadována 24 bitová hloubka barev! Podívejte na instrukce uvedené níže, které uvádějí jak provést tuto konfiguraci.

Testované karty:
  • NVIDIA GeForce 2 nebo ekvivalentní karta používající verzi NVIDIA ovladačů 1.0-5336 a 1.0-6629 .
    Prosím, přečtěte si Tipy pro instalaci ovladačů NVIDIA.

    POZNÁMKA: Je obzvlášť důležité projít tyto instrukce jestliže jste nově aktualizovali ovladač na 1.0-6629, neboť LG3D vyžaduje dodatečné konfigurační kroky pro verzi 1.0-6629.

Instrukce pro konfiguraci ovladačů specifických karet najdete v dokumentu: Instalace a konfigurace ovladačů pro 3D Desktop Projekt Looking Glass

Pokud jste byli úspěšní při zprovoznění Projektu Looking Glass na jiných grafických kartách nebo chcete nahlásit problémy se specifickou kartou, dejte nám prosím vědět prostřednictvím diskusního fóra

Místo na disku 350MB

2. Nastavení prostředí pro Projekt Looking Glass

Ještě než budete moci spustit Projekt Looking Glass, musíte nainstalovat několik Java komponent. Nejjednodušší cestou je stáhnout všechny komponenty a poté je nainstalovat v níže uvedeném pořadí.

Stáhněte komponenty

Poznámka: Instalační instrukce předpokládají, že všechny komponenty stáhnete do adresáře /tmp.

  1. Java 2 SDK, Standard Edition 1.5.0 nebo pozdější.
    http://java.sun.com/j2se/1.5.0/download.jsp

    Poznámka: Níže uvedené instrukce pro instalaci předpokládají stažení RPM verze JDK.

  2. Java 3D SDK 1.3.2 nebo pozdější
    https://j3d-core.dev.java.net/servlets/ProjectDocumentList

    Poznámka: Přejděte do podadresáře j3d-core/Release_Builds/1.3.2 a stáhněte java3d-1_3_2-linux-i586.zip.



  3. Java Advanced Imaging API (JAI) 1.1.2 JDK
    http://java.sun.com/products/java-media/jai/downloads/download-1_1_2.html

    Poznámka: Zvolte JDK(TM) Install: Bundle for installation in a JDK Download. Po přečtení a odsouhlasení Software License Agreement (licence) vyberte položku Linux JDK Install (jai-1_1_2-lib-linux-i586-jdk.bin).

Nainstalujte komponenty

Poté co jste stáhli všechny komponenty, nainstalujte je podle následujících instrukcí.

  1. Nejprve se přepněte na uživatele root:

    % su root
    Password:
    enter root password
    #

  2. Nainstalujte Java 2 SDK:

    # cd /tmp
    # /bin/bash jdk-1_5_0_02-linux-i586-rpm.bin
    # rm jdk-1_5_0_02-linux-i586.rpm
    # rm jdk-1_5_0_02-linux-i586-rpm.bin


  3. Nainstalujte Java 3D SDK:

    # cd /tmp
    # unzip java3d-1_3_2-linux-i586.zip
    # cd /usr/java/jdk1.5.0/jre
    # unzip /tmp/java3d-1_3_2-linux-i586/j3d-132-linux-x86.zip
    # cd /tmp
    # rm -r java3d-1_3_2-linux-i586/


  4. Nainstalujte Java Advanced Imaging API:

    # cd /usr/java/jdk1.5.0
    # /bin/bash /tmp/jai-1_1_2-lib-linux-i586-jdk.bin


  5. Opusťte root shell:

    # exit
    %


  6. Nyní je třeba nastavit několik proměnných prostředí v profilu vašeho shellu. Zde je příklad pro bash(1):

    JAVA_HOME=/usr/java/jdk1.5.0
    PATH=$JAVA_HOME/bin:$PATH

3. Nainstalování Vývojářské verze Projektu Looking Glass

Zaregistrujte se na webu java.net

Pokud již nejste zaregistrováni na java.net, pak si budete muset založit účet:

  1. Přejděte na http://www.java.net a klikněte na odkaz Register v horní části stránky.
  2. Zadejte zvolené uživatelské jméno a emailovou adresu a stiskněte tlačítko [Register].
  3. Přijde vám email s instrukcemi pro nastavení hesla vašeho účtu. Poté co vložíte heslo a odsouhlasíte podmínky registrace na webu java.net, budete přihlášeni.

Stáhněte instalační balíček Projektu Looking Glass

  1. Jděte na stránky https://lg3d-core.dev.java.net a klikněte na Documents & files v sekci Project tools na postranní liště.
  2. Přejděte do lg3d-core/stable_builds ve stromu v pravé části panelu. Zobrazí se vám tabulka se seznamem stabilních buildů.
  3. Klikněte na odkaz pojmenovaný Release_x.y.z (kde x.y.z je verze buildu, například 0.6.1) a zvolte adresář, kam bude soubor stáhnut, jako třeba /tmp
  4. Změňte aktuální adresář na adresář kam budete chtít Projekt Looking Glass nainstalovat a rozbalte soubory:

    % cd /home/username
    % tar -zxf /tmp/lg3d-x.y.z.tar.gz


    Poznámka: Nahraďte x.y.z verzí buildu, který jste stáhli (např. 0.6.1).

    Soubory budou rozbaleny do adresáře lg3d umístěného v aktuálním adresáři.
Aktuální verze LG3D je verze 0.6.1. Než začnete tuto verzi používat, přečtěte si i Poznámky k verzi.

Nastavte barevnou hloubku vašeho displeje

Vývojářská verze Projektu Looking Glass vyžaduje nejméně 24 bitovou barevnou hloubku. Mnoho systémů je však nakonfigurováno se 16-ti bitovou barevnou hloubkou a Vývojářská verze Projektu Looking Glass nebude v této barevné hloubce pracovat správně. Aktuální nastavení barev vašeho displeje můžete zjistit spuštěním následujícího příkazu:

% xdpyinfo | grep "depth of root"
depth of root window:   24 planes

Pokud se zobrazí hodnota menší než 24, musíte změnit nastavení barevné hloubky. Proces změny nastavení hloubky barev se liší pro různé platformy. Podívejte se proto na konfigurační instrukce pro vaši platformu, uvedené níže:

Java Desktop System 1 a 2, a SUSE8.1:

  1. From within a desktop session, run the sax2 command:

    % /usr/X11R6/bin/sax2
    SaX: root Password:
    enter root password

  2. In the SaX2 application, click on Color and Resolution then click the [Properties...] button for the currently configured desktop.
  3. In the Color selection... panel, click on the the menu and choose 16.7 Mio. [24 Bit].
  4. On the Resolution(s) for 16.7 Mio. [24 Bit] colors tab, select the preferred resolution for your desktop and press [Ok].
  5. Click the [Finish] button, then [Finalize>>].
  6. The SaX2 final steps... dialog will open. Click the [Test...] button to test the new resolution.
  7. A blue test screen should appear, click the [Save] button if the display appears to be stable, and then [Ok] when you return to the SaX2 window, followed by [Yes] to exit from SaX2.
  8. If the test screen did not appear correctly, the test will exit after 30 seconds and your previous desktop session will be restored. You should then try alternate resolutions at the 24 bit color depth to find a resolution that works for your system.
  9. When you are satisfied with the settings, log out and re-login to your desktop session and verify that the color depth is now 24 bit or higher using the xdpyinfo command above.

RedHat Fedora 2:

  1. First become root:

    % su root
    Password:
    enter root password
    #

  2. Edit the file: /etc/X11/xorg.conf
  3. Locate the section of the file labeled: Section "Screen"
  4. Within this section, locate the entry: Identifier "Screen0"
    Change the DefaultDepth and DefaultFbBpp properties to:

    DefaultDepth 24
    DefaultFbBpp 32

  5. Save the file and then logout and re-login to your desktop session and verify that the color depth is now 24 bit or higher using the xdpyinfo command above.

RedHat 8, RedHat 9 and other Linux platforms:

Many Linux platforms use the XF86Config file to configure the display properties. To change the color depth on these systems:

  1. First become root:

    % su root
    Password:
    enter root password
    #

  2. Edit the file: /etc/X11/XF86Config
  3. Locate the section of the file labeled: Section "Screen" and change the DefaultDepth property to 24:

    DefaultDepth     24

  4. Within this section, locate the sub-section labeled "Display":

    SubSection "Display"

    and change the Depth property to:

    Depth     24

  5. Save the file and then logout and re-login to your desktop session and verify that the color depth is now 24 bit or higher using the xdpyinfo command above.

4. Running Project Looking Glass

There are two ways to run Project Looking Glass; in a window within an existing desktop environment and as a full-screen desktop. Only the full-screen desktop mode supports a key Project Looking Glass feature, the integration of native, unmodified X11 applications. The easiest way to verify that your Project Looking Glass installation is correct is to run the demo within an existing desktop. Once you're satisfied that it is working correctly, you can then configure your system to run Project Looking Glass full-screen. Note that running Project Looking Glass in a desktop window is a good way to develop and test 3D applications and enhancements to the Window Manager (Scene Manager).

Running Project Looking Glass within an existing desktop environment

In this mode, a Project Looking Glass session runs in a window in your desktop. This is the simplest way to run Project Looking Glass but this mode only allows you to run Project Looking Glass 3D applications, such as the CD chooser. X11 applications, such as xterm will appear in the X session that you launched the Project Looking Glass session from.

  1. Log into your account and change directory to where you installed Project Looking Glass:

    % cd /home/username/lg3d/bin

  2. And start the Project Looking Glass session:

    % ./lg3d-dev

If you have successfully installed Project Looking Glass you should see the familiar Project Looking Glass desktop in a window on your desktop:

Project Looking Glass Screenshot

Clicking the CD icon on the taskbar will open the CD viewer, a 3D demo application. Mouse over the stack of CDs and click on the CD images to see the application in action. For addtional operational information, click the icon to the left of the CD Viewer on the taskbar. This will open a panel that summarizes the operations supported by the demo. Note that the left most icon, a computer, launches an xterm window. This item demonstrates X11 application integration and is only supported in full-screen mode. See the next section for configuration information.

Running Project Looking Glass full-screen

This mode allows you to run Project Looking Glass full-screen and launch any application, including native X11 applications. You must first shutdown your X session before starting Project Looking Glass. This mode can only be used on Linux systems. Eventually, this will become the primary mode for running LG3D and will be supported both on Linux and Solaris systems.

NOTE: This mode is still very much a work in progress. To date, only a few X11 applications run bug-free in this mode. There is still a lot of debugging work left to do. Important applications such as mozilla, staroffice, evolution, realplayer, and most GNOME applications still have significant problems. We are actively addressing these problems. Please file issues on any problems you find.

The instructions vary by platform, so follow the instructions that apply to your platform. If your platform isn't listed, chances are the process will be very similar so use these instructions as a guide and let us know what's different!

Sun Java Desktop System/SuSE 8.1:

JDS/SuSE 8.1 uses the X Display Manager (xdm) to manage user sessions. To run Project Looking Glass you must first shut down xdm. Since this process is respawned automatically you must disable this service using the chkconfig command:

  1. First become root:

    % su root
    Password:
    enter root password
    #

  2. Disable the xdm service:

    # /sbin/chkconfig -d xdm
    xdm  0:off   1:off   2:off   3:off   4:off   5:off   6:off

  3. Now close any desktop applications and save any open files. Then shutdown the display manager:

    # pkill gdm-binary

  4. Now skip to the Starting the Project Looking Glass desktop session section.

Note: To re-activate the X Display manager, enter the following command as root, and then reboot your system:

# /sbin/chkconfig -a xdm

RedHat 9:

RedHat uses the GNOME Display Manager (gdm) to manage user sessions. It's not necessary to disable gdm, you can simply switch to a lower run level where gdm is not active:

  1. First become root:

    % su root
    Password:
    enter root password
    #

  2. Close any desktop applications and save any open files. Then switch to run level 4:

    # /sbin/init 4

    Your X session should terminate and your should return to the console prompt.

  3. Now skip to the Starting the Project Looking Glass desktop session section.

Note: To restart the GNOME Display Manager, enter the following command as root from the console:

# /sbin/init 5

Fedora Core 3 64-bit:

To run Project Looking Glass full screen on the 64-bit version of Fedora Core 3 requires a few unique changes. Note that you will need access to a 32-bit Linux system or the 32-bit X11 modules for Linux to complete this procedure.

  1. You will need to copy the contents of the /usr/X11R6/lib/modules directory from a 32-bit Linux system to the same directory on your 64-bit system. Before performing this action, make a backup of the /usr/X11R6/lib/modules directory on your 64-bit system:

    # cd /usr/X11R6/lib
    # cp -r modules modules.orig

    Next, use the scp command to securely copy the files from the 32-bit system to your 64-bit system:

    # scp -r root@32bithost:/usr/X11R6/lib/modules /usr/X11R6/lib/modules

    where 32bithost is the host name of the 32-bit Linux system.

  2. Make sure that your xorg.conf file is set for depth of 24 as shown in bold below:

    Section "Screen"
    Identifier "Screen0"
    Device "Videocard0"
    Monitor "Monitor0"
    DefaultDepth 24
    SubSection "Display"
    Viewport 0 0
    Depth 24
    Modes "1680x1050" "1280x800" "1024x768" "800x600" "640x480"
    EndSubSection
    EndSection

  3. Proceed to the next section to start the full screen session.

    [Instructions in this section courtesy of qgonjon and marve. See this support thread.]

Starting the Project Looking Glass desktop session

To start a Project Looking Glass desktop session from the console (not within an X session):

  1. Become root and change directory to where you installed Project Looking Glass:

    # cd /home/username/lg3d/bin

  2. Start the Project Looking Glass desktop session:

    # ./lg3d-session

    After a few seconds, the Project Looking Glass desktop should appear. Congratulations! If you have problems starting the desktop session, refer to the Troubleshooting section for assistance.

Explore the Project Looking Glass desktop and start dreaming of new ways to enhance the desktop user experience with 3D! When you're ready to do development, skip over to the Project Looking Glass Developer's Guide for information about developing with Project Looking Glass.

5. Troubleshooting

no core pointer

This happens on RedHat Fedora Core 2, and may happen on other configurations as well. One known workaround (from sgiunchi) is to do the following (as root user):

# ln -s /etc/X11/xorg.conf /etc/X11/XF86Config-4

The correct long term fix is to upgrade the X11 release which is included in lg3d-core. It is currently an Xorg 6.7 pre-release and it needs to be upgraded to the latest Xorg stable release.

Exception in thread "main" java.lang.UnsatisfiedLinkError: /usr/java/jdk1.5.0/jre/lib/i386/libj3dcore-ogl.so:
/usr/java/jdk1.5.0/jre/lib/i386/libj3dcore-ogl.so: symbol glMultiDrawArraysEXT, version LIBGL not defined in file libGL.so.1 with link time reference

This error occurs with ATI device drivers that are missing the glMultiDrawArraysEXT extension. The solution to this problem is to replace the Radeon device drivers with drivers from the Direct Rendering Open Source (DRI) project. For instructions on installing direct rendering drivers refer to DRI driver installation for ATI Radeon.

Note that upgrading libGL.so to the latest Mesa libraries does not solve this problem.

pkill: 27863 - Operation not permitted
java.rmi.server.ExportException: Port already in use: 1099; nested exception is:
      java.net.BindException: Address already in use...

This message indicates that an rmiregistry process is already running and lg3d-dev was unable to start a new instance. Typically this occurs when the rmiregistry process was started by root and lg3d-dev is run as a non-root user. The solution to this problem is to stop the root instance of rmiregistry. Become root and stop the process:

% su root
Password: enter root password
# pkill rmiregistry
# exit

Now re-run the lg3d-dev command as a non-root user to start Project Looking Glass.

Fatal Server error: Cannot establish any listening sockets

The following error message is displayed when you start Project Looking Glass using lg3d-session:

_XSERVTransSocketUNIXCreateListener: ...SocketCreateListener() failed
_XSERVTransMakeAllCOTSServerListeners: server already running

Fatal server error:
Cannot establish any listening sockets - Make sure an X server
isn't already running

First, make sure that you do not have an X11 session running on the display on which you're starting lg3d-session. Then check to see if you have /tmp/.X11-unix/X0 left behind from a previous session. To fix this problem, delete this file and restart lg3d-session.

Screen updates are very slow

This usually means that graphics acceleration is not correctly configured. Here are some things to check first:

libGL error: failed to open DRM: operation not permitted

(This error may be encountered when running lg3d-dev).

If Project Looking Glass runs very slowly, even though 3D acceleration is enabled, check to see if the following message appears in the console:

libGL error: failed to open DRM: Operation not permitted
libGL error: reverting to (slow) indirect rendering

This means that your user account doesn't have permission to use the DRI (Direct Rendering Infrastructure). In some cases root is the only user with access to Direct Rendering. This problem seems to only affect RedHat users, and not JDS/SuSE users. If you have this problem, you should change the DRI permissions in your XFree86Config or XF86Config file to:

Section "DRI"
Group "video"
Mode 0666
EndSection

You will also need to change the permissions of the <dri> profile in /etc/security/console.perms from 0600 to 0666:

<xconsole> 0600 <dri> 0666 root

and if you're using an NVIDIA card, change the permissions on /dev/nvidia* to 0666:

# chmod a+rw /dev/nvidia*

An unexpected exception has been detected in native code outside the VM

Project Looking Glass exits with the following exception, even though you've verified that you have 3D acceleration enabled:

An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : 11 occurred at PC=0x0
Function=[Unknown.]
Library=(N/A)

Check to see if the following entries appear in the exception message:

<addr-range> r-xp 00000000 03:05 61763 /usr/lib/GL/libGL.so.1.3.mesasoft
<addr-range> rw-p 001b4000 03:05 61763 /usr/lib/GL/libGL.so.1.3.mesasoft

If so, you have the MESA software OpenGL libraries installed. Use the package tool for your distribution (e.g., rpm) to remove these libraries, and then go into /usr/lib as root and check that the following symbolic links exist and point to the correct OpenGL libraries. You should have links that look something like this (where x and y are numbers):

libGLcore.so.1 -> libGLcore.so.1.x
libGL.so -> libGL.so.x
libGLU.so -> libGLU.so.x.y.z

If these links are not correct, become root and create them. For example, if you have a libGLU.so.1 file but no libGLU.so link, then create the link:

# ln -s /usr/lib/libGLU.so.1 /usr/lib/libGLU.so

Repeat this for each of the links that are missing.

Failed to load the NVIDIA driver

There are several possible reasons for the driver failing to initialize correctly:

See also:

Project Looking Glass Developer's Release Notes

Additional information on current problems and issues can be found under lg3d-core Project Tools > Issue tracker. You can search for issues and defects or find a specific issue.

6. Staying connected with Project Looking Glass

The Project Looking Glass project is evolving continually. The best way to keep up to date with Project Looking Glass developments is by subscribing to the Project Looking Glass mailing lists. Click on Mailing lists in the Project tools section of the side bar on https://lg3d.dev.java.net/. There are several mailing lists to choose from depending on your level of interest.

7. Some final words

Thanks for getting involved with the Project Looking Glass project! We're really looking forward to your contributions in this exciting new desktop experience!

The Project Looking Glass Development Team

See also:

Project Looking Glass Developer's Release Notes
Project Looking Glass Developer's Guide
Installing and Configuring Device Drivers for 3D Desktop Project Looking Glass


$Revision: 1.1 $ $Date: 2005/05/24 18:05:38 $ (English Version Revision: 1.26)