Upcoming Events
Unite 2010
11/10 - 11/12 @ Montréal, Canada

GDC China
12/5 - 12/7 @ Shanghai, China

Asia Game Show 2010
12/24 - 12/27  

GDC 2011
2/28 - 3/4 @ San Francisco, CA

More events...
Quick Stats
103 people currently visiting GDNet.
2406 articles in the reference section.

Help us fight cancer!
Join SETI Team GDNet!
Link to us Events 4 Gamers
Intel sponsors gamedev.net search:

  Contents

 Introduction
 The Problem
 The Solution
 Using the
 OpenGL Module


 Printable version

 


The Problem

Supporting hardware acceleration with OpenGL is normally as easy as writing an OpenGL program; if the user has 3d hardware, then it will be used to accelerate OpenGL programs via its OpenGL ICD. Enter the problem: the ICD driver was designed long before the introduction of the Voodoo1 and it really wasn't meant for supporting more than one graphics card (ie a separate 3D card and 2D card for example). Therefore it is *IMPOSSIBLE* to have an ICD driver for cards that meet this criteria. Enter the Voodoo1/2 cards, they do have a full OpenGL driver, named 3dfxvgl.dll, but it is not an ICD and as such will not be supported by linking your application to opengl32.lib.

So how does an ICD work?

Not so fast my eager reader - first some fundamentals. OpenGL drivers on windows machines are implemented as a DLL named (appropriately enough) OpenGL32.dll. Every 32-bit windows OS comes with this DLL (except the very original Win95 retail edition, for which it is available as a free download from Microsoft). This is the MS software OpenGL renderer, which is a full implementation of OpenGL 1.1. Now, when you clunk in that favorite 3D card and install the drivers for it, it also installs another OpenGL driver which is named differently depending on your card, (as am example - in the case of my RivaTNT its something like nvogl.dll) it also updates the registry to tell the system that an ICD has been installed and what the name of the ICD dll is. So enter an OpenGL program, it loads OpenGL32.dll when it starts (automagically because it was linked to opengl32.lib), and when it makes OpenGL function calls they are directed at the OpenGL32.dll, which in turn forwards them on to the ICD driver.


Next : The Solution