> # TOPIC

> glut - using Cg with the OpenGL Utility Toolkit (GLUT)

> # ABSTRACT

> GLUT provides a cross-platform window system API for writing OpenGL examples and demos. For this reason, the Cg examples packaged with the Cg Toolkit rely on GLUT.

> # WINDOWS INSTALLATION

> The Cg Toolkit installer for Windows provides a pre-compiled 32-bit (and 64-bit if selected) versions of GLUT. GLUT is provided both as a Dynamic Link Library (DLL) and a static library.

> The GLUT DLL is called glut32.dll and requires linking against glut32.lib. These 32-bit versions are typically installed at:

>       c:\Program Files\NVIDIA Corporation\Cg\bin\glut32.dll
>       c:\Program Files\NVIDIA Corporation\Cg\lib\glut32.lib

> The 64-bit (x64) versions are installed at:

>       c:\Program Files\NVIDIA Corporation\Cg\bin.x64\glut32.dll
>       c:\Program Files\NVIDIA Corporation\Cg\lib.x64\glut32.lib

> As with any DLL in Windows, if you link your application with the GLUT DLL, running your application requires that glut32.dll can be found when executing GLUT.

> Alternatively you can link statically with GLUT. This can easily be done by defining the GLUT_STATIC_LIB preprocessor macro before including GLUT's header file. This is typically done by adding the -DGLUT_STATIC_LIB option to your compiler command line. When defined, a #pragma in requests the linker link against glutstatic.lib instead of glut32.lib.

> The 32-bit and 64-bit versions of the GLUT static library are installed at:

>       c:\Program Files\NVIDIA Corporation\Cg\lib\glutstatic.lib
>       c:\Program Files\NVIDIA Corporation\Cg\lib.x64\glutstatic.lib

> # SEE ALSO

> TBD