Next Previous Contents

9. FAQ: OpenGL/Mesa?

9.1 What is OpenGL?

OpenGL is an immediate mode graphics programming API originally developed by SGI based on their previous proprietary Iris GL, and became in industry standard several years ago. It is defined and maintained by the Architectural Revision Board (ARB), an organization that includes members as SGI, IBM, and DEC, and Microsoft.

OpenGL provides a complete feature set for 2D and 3D graphics operations in a pipelined hardware accelerated architecture for triangle and polygon rendering. In a broader sense, OpenGL is a powerful and generic toolset for hardware assisted computer graphics.

9.2 Where to get additional information on OpenGL?

The official site for OpenGL maintained by the members of the ARB, is www.opengl.org,

A most recommended site is Mark Kilgard's Gateway to OpenGL Info at reality.sgi.com/mjk_asd/opengl-links.html: it provides pointers to book, online manual pages, GLUT, GLE, Mesa, ports to several OS, tons of demos and tools.

If you are interested in game programming using OpenGL, there is the OpenGL-GameDev-L@fatcity.com at Listserv@fatcity.com. Be warned, this is a high traffic list with very technical content, and you will probably prefer to use procmail to handle the 100 messages per day coming in. You cut down bandwidth using the SET OpenGL-GameDev-L DIGEST command. It is also not appropriate if you are looking for introductions. The archive is handled by the ListServ software, use the INDEX OpenGL-GameDev-L and GET OpenGL-GameDev-L "filename" commands to get a preview before subscribing.

9.3 Is Glide an OpenGL implementation?

No, Glide is a proprietary 3Dfx API which several features specific to the Voodoo Graphics (tm) and Voodoo Rush (tm). A 3Dfx OpenGL is in preparation (see below). Several Glide features would require EXTensions to OpenGL, some of which already found in other implementations (e.g. paletted textures).

The closest thing to a hardware accelerated Linux OpenGL you could currently get is Brian Paul's Mesa along with David Bucciarelli's Mesa Voodoo driver (see below).

9.4 Is there an OpenGL driver from 3Dfx?

Both the 3Dfx website and the Quantum3D website announced OpenGL for Voodoo Graphics (tm) to be available 4Q97. The driver is currently in Beta, and accessible only to registered deverloper's under written Beta test agreement.

A linux port has not been announced yet.

9.5 Is there a commercial OpenGL for Linux and 3Dfx?

I am not aware of any third party commercial OpenGL that supports the Voodoo Graphics (tm). Last time I paid attention, neither MetroX nor XInside OpenGL did.

9.6 What is Mesa?

Mesa is a free implementation of the OpenGL API, designed and written by Brian Paul, with contributions from many others. Its performance is competitive, and while it is not officially certified, it is an almost fully compliant OpenGL implementation conforming to the ARB specifications - more complete than some commercial products out, actually.

9.7 Does Mesa work with 3Dfx?

The latest Mesa MesaVer; release works with Linux Glide 2.4. In fact, support was included in earlier versions, however, this driver is still under development, so be prepared for bugs and less than optimal performance. It is steadily improving, though, and bugs are usually fixed very fast.

You will need to get the Mesa library archive from the iris.ssec.wisc.edu FTP site. It is recommended to subscribe to the mailing list as well, especially when trying to track down bugs, hardware, or driver limitations. Make sure to get the most recent distribution. A Mesa-3.0 is in preparation.

9.8 How portable is Mesa with Glide?

It is available for Linux and Win32, and any application based on Mesa will only have the usual system specific code, which should usually mean XWindows vs. Windows, or GLX vs. WGL. If you use e.g. GLUT or Qt, you should get away with any system specifics at all for virtually most applications. There are only a few issues (like sampling relative mouse movement) that are not adressed by the available portable GUI toolkits.

Mesa/Glide is also available for DOS. The port which is 32bit DOS is maintained by Charlie Wallace and kept up to date with the main Mesa base. See www.geocities.com/~charlie_x/.for the most current releases.

9.9 Where to get info on Mesa?

The Mesa home page is at www.ssec.wisc.edu/~brianp/Mesa.html. There is an archive of the Mesa mailing list. at www.iqm.unicamp.br/mesa/. This list is not specific to 3Dfx and Glide, but if you are interested in using 3Dfx hardware to accelerate Mesa, it is a good place to start.

9.10 Where to get information on Mesa Voodoo?

For latest information on the Mesa Voodoo driver maintained by David Bucciarelli tech.hmw@plus.it see the home page at www-hmw.caribel.pisa.it/fxmesa/.

9.11 Does Mesa support multitexturing?

Not as of Mesa 2.6, but it is already in the upcoming Mesa 3.0 revision. In Mesa 3.0 the device drivers will be able to advertise their own set of extensions. Testing for 1 vs. 2 TMU will be done by the Mesa driver forf %Voodoo Graphics (tm) and Voodoo 2 (tm), at runtime. You will have to use the OpenGL EXT_multitexture extension once it is available, as described in the upcoming OpenGL 1.2 revision. Mesa 3.0 uses the GL_SGIS_multitexture extension, which supports separate texture coordinate sets and all current texture environment (blending) modes.

However, the work is not yet done. See acknowledgement section on OEM support for details.

9.12 Does Mesa support single pass trilinear mipmapping?

Multiple TMU's should be used for single pass trilinear mipmapping for improvement image quality without performance penalty in current Linux Glide already. Mesa support is not available as of Mesa 2.6, but is in preparation for Mesa 3.0 (see above on multitexturing).

Note that single pass trilinear mipmapping and multitexturing are mutually exclusive - you could either blend two textures in a single pass, or do a full trilinear mipmapping using two mipmap resolution levels. To do it all combined, you would need more than 2 Texelfx in a single pipeline.

9.13 What is the Mesa "Window Hack"?

The most recent revisions of Mesa contain an experimental feature for Linux XFree86. Basically, the GLX emulation used by Mesa copies the contents of the Voodoo Graphics (tm) board's most recently finished framebuffer content into video memory on each glXSwapBuffers call. This feature is also available with Mesa for Windows.

This obviously puts some drain on the PCI, doubled by the fact that this uses X11 MIT SHM, not XFree86 DGA to access the video memory. The same approach could theoretically be used with e.g. SVGA. The major benefit is that you could use a Voodoo Graphics (tm) board for accelerated rendering into a window, and that you don't have to use the VGA passthrough mode (video output of the VGA board deteoriates in passing through, which is very visible with high end monitors like e.g. EIZO F784-T).

Note that this experimental feature is NOT Voodoo Rush (tm) support by any means. It applies only to the Voodoo Graphics (tm) based boards. Moreover, you need to use a modified GLUT, as interfacing the window management system and handling the events appropriately has to be done by the application, it is not handled in the driver.

Make really sure that you have enabled the following environment variables:


export SST_VGA_PASS=1          # to stop video signal switching
export SST_NOSHUTDOWN=1        # to stop video signal switching
export MESA_GLX_FX="window"    # to initiate Mesa window mode

If you manage to forget one of the SST variables, your VGA board will be shut off, and you will loose the display (but not the actual X). It is pretty hard to get that back being effectively blind.

Finally, note that the libMesaGL.a (or .so) library can contain multiple client interfaces. I.e. the GLX, OSMesa, and fxMesa (and even SVGAMesa) interfaces call all be compiled into the same libMesaGL.a. The client program can use any of them freely, even simultaneously if it's careful.

9.14 How about GLUT?

Mark Kilgard's GLUT distribution is a very good place to get sample applications plus a lot of useful utilities. You will find it at reality.sgi.com/mjk_asd/glut3/, and you should get it anyway. The current release is GLUT 3.6, and discussion on a GLUT 3.7 (aka GameGLUT) has begun. Note that Mark Kilgard has left SGI recently, so the archive might move some time this year - for the time being it will be kept at SGI.

There is also a GLUT mailing list, glut@perp.com. Send mail to majordomo@perp.com, with the (on of the) following in the body of your email message:


   help
   info glut
   subscribe glut
   end

As GLUT handles double buffers, windows, events, and other operations closely tied to hardware and operating system, using GLUT with Voodoo Graphics (tm) requires support, which is currently in development within GLX for Mesa. It already works for most cases.


Next Previous Contents