The Solaris OpenGL software is Sun's native implementation of the OpenGL application programming interface (API). The OpenGL API is an industry-standard, vendor-neutral graphics library. It provides a small set of low-level geometric primitives and many basic and advanced 3D rendering features, such as modeling transformations, shading, lighting, anti-aliasing, texture mapping, fog, and alpha blending.
The Solaris OpenGL 1.1.2 software supports the following devices:
Creator Graphics and Creator3D Graphics - OpenGL functionality is accelerated in hardware.
SX, GX, GX+, TGX, TGX+, S24 - OpenGL functionality is performed in software.
All Sun SPARCTM systems equipped with the following frame buffers are supported on the OpenGL 1.1.2 software: the TCX, SX, GX, Creator, and Elite3D families of frame buffers. This includes UltraTM desktop, Sun EnterpriseTM and all the legacy SPARCstationTM family.
If you have older versions of the Solaris OpenGL software packages, you must use the pkgrm command to remove them. Follow these steps:
Check to see whether any older versions of the OpenGL packages are installed using the pkginfo command.
The pkginfo | egrep -i "OpenGL" command lists any existing OpenGL packages that you have installed.
% pkginfo | egrep -i "OpenGL" application SUNWffbgl Creator Graphics (FFB) OpenGL Support application SUNWglrt OpenGL Runtime Libraries application SUNWglrtu OpenGL Platform Specific Runtime Libraries application SUNWglwrt OpenGL Widget Library application SUNWafbgl Loadable pipeline for UPA Bus Elite3D graphics application SUNWgldoc Solaris OpenGL Documentation and Man Pages application SUNWglh Solaris OpenGL Header Files application SUNWglut Solaris OpenGL Utilities and Example Programs application SUNWglwh Solaris OpenGL Widget Header Files
To remove the packages, become superuser:
% su Password: superuser password
Run pkgrm to remove all existing Solaris OpenGL packages.
# pkgrm SUNWglrt SUNWglh...
To install the OpenGL software, follow these steps:
Start CDE or OpenWindows.
Insert the Supplement CD into your CD-ROM drive.
The File Manager window is displayed.
Open a command window and become superuser using the su command and superuser password.
Enter the swmtool command at the # prompt:
# /usr/sbin/swmtool
The Admintool:Software window is displayed.
Select Add from the Edit Menu.
The Admintool:Set Source Media window is displayed.
# cd /cdrom/cdrom0/Product
The Admintool:Add Software window is displayed
In the Admintool:Add Software window, select Open GL Runtime Libraries 1.1.2.
Click Add.
The installation process should take a few minutes.
Quit Admintool.
Table 3-5 lists the clusters and packages that are provided with Solaris OpenGL.
Table 3-5 OpenGL Clusters and Packages
Cluster Name |
Package Name |
Description |
Default Install Location |
---|---|---|---|
SUNWCogl |
SUNWglrt |
OpenGL client-side runtime libraries |
/usr/openwin/lib |
SUNWglrtu |
UltraSPARC-specific OpenGL libraries |
/usr/openwin/platform/sun4u/lib/GL |
|
SUNWffbgl |
Device pipeline for Creator and Creator3D Graphics frame buffers |
/usr/openwin/lib/GL/devhandlers |
|
SUNWglwrt |
OpenGL widget library |
/usr/openwin/lib |
|
SUNWafbgl |
Loadable pipeline for UPA Bus Elite3D graphics |
/usr/openwin |
|
SUNWglrtx | Sun OpenGL 64-bit Runtime Libraries | /usr/openwin | |
SUNWafbgx | Sun OpenGL 64-bit loadable pipeline for the UPA Bus Elite3D graphics accelerator | /usr/openwin | |
SUNWffbgx | Sun OpenGL 64-bit loadable pipeline for the UPA Bus Creator graphics accelerator | /usr/openwin |
After installing the packages, do the following:
Exit the window system and restart it so that the window system loads the newly installed GLX server extension.
To verify that the OpenGL libraries are installed correctly, run ogl_install_check.
The ogl_install_check test program prints the version of the OpenGL library and renderer used, and renders a rotating wheel. The program returns the following output when it is run on an UltraSPARC Creator3D:
OpenGL Vendor: Sun Microsystems, Inc. OpenGL Version: 1.1.2 Solaris OpenGL 1.1.2_08
For diagnostic purposes, the following values should be noted anytime that Solaris OpenGL problems are seen:
OpenGL Renderer: Creator 3D, VIS OpenGL Extension Support: GL_EXT_texture3D GL_SGI_color_table GL_SUN_geometry_compression GL_EXT_abgr GL_EXT_rescale_normal OpenGL GLX Server: Detail Status Report GLX: Context is direct. GLX: OpenGL Rendering in use GLX: Double Buffering in use GLX: Color Buffer (GLX_BUFFER_SIZE) = 24 bits GLX: Depth Buffer (GLX_DEPTH_SIZE) = 28 bits GLX: Stencil Buffer (GLX_STENCIL_SIZE) = 4 bits GLX: RGBA (True Color/Direct Color) Visual in use OpenGL Library: Detail Status Report Number of color bits (R/G/B/A): 8/8/8/0 Frame Buffer Depth (GL_DEPTH_BITS):28
Whenever possible, Solaris OpenGL renders directly to the frame buffer, bypassing the X server. This is enabled by Sun's DGA mechanism for locking portions of the screen. However, a Solaris security feature only allows the user who originally logged in to the window system to use DGA to lock portions of the screen. Only owners of the window system have access to DGA.
If you notice poor performance when rendering locally, the cause may be this Solaris security feature. For example, if you start the window system, and another user at the workstation changes to that user's own environment using su, the application will not run via DGA even though the second user is running the application locally.
If you notice slow local rendering, run the ogl_install_check diagnostic program (found in /usr/openwin/demo/GL) to determine whether the application is running via DGA. If the OpenGL GLX Server status report from the ogl_install_check program says that the GLX context is indirect, the login permissions need to be edited to enable DGA access for all users.
To give all local users access to DGA, follow these steps:
% su Password: superuser password
Edit permissions to allow world read/write access to the following devices:
% chmod 666 /dev/mouse /dev/kbd /dev/sound/* /dev/fbs/*
This will enable DGA access by all users for the duration of the current window system session (subject to X authorization, see xhost(1)).
Edit the /etc/logindevperm file and change the default permissions of all devices listed in the file to 0666 to allow world read/write access.
For example, in the following lines in logindevperm, the 0600 should be changed to 0666 so that the next time you log in and restart your window system, it will still be accessible by all users.
/dev/console 0600 /dev/mouse:/dev/kbd /dev/console 0600 /dev/sound/* # audio devices /dev/console 0600 /dev/fbs/* #frame buffers
Note that your system is no longer secure.