Developers wishing to join as a member of the project are very welcome. Please contact me to add you to the list.
Similar functionality exists for C developers in the form of GLUT. However, it is not always easy to interface this with C++. It is also difficult to interface with Motif since GLUT has it's own event processing loop which you can't break into.
In addition, other useful functionality will be included that will allow
images (.bmp, .raw, .tga etc..) and 3d object format files (.3ds, .asc,
.dxf etc..) to be loaded in a platform independant way.
At present the library is undergoing major development. However, an early release (v0.0.1) is available for you to use. This contains enough functionality to create any number of OpenGL windows and assign certain events (KeyPress, Display, Resize) to each of them.
If you wish to contribute to this project in some way then please feel free to contact me
To show how the library can be used, consider the following example:
In order to compile this example you would need to add the following to your makefile:
int end = 0;
// Initialise GL stuff here
void myKeyPressEventRoutine(int key)
end = 1;
void myResizeEventRoutine(int width, int height)
// Your window resize code would go here
// Your display code would go here
int main(int argc, const char **argv)
// --== Define the title of our window ==--
char title = "OpenGL Class Library (GLCL) : Simple Test Program";
// --== Attempt to create an OpenGL window and assign all events to it ==--
// --== Create an OpenGL window ==--
window = new GLWindow(argc, argv, title, 640, 480);
// --== Assign the events to this window ==--
// --== Catch any exceptions that may have been thrown ==--
// --== Get reason for exception and display it ==--
cout << "Exception caught: " << glcl.GetReason() << endl;
// --== Initialise any OpenGL parameters for our program ==--
// --== The main loop - stay in here until you need to exit ==--
// --== Update the window ==--
// --== Ensure we clean up ==--
Library path: /usr/local/glcl/lib
For examples, see the demo programs supplied in the 'test' directory
Please note that I do not claim to be an expert in C++, nor do I claim to be an expert in OpenGL. This library came about through a need to create OpenGL applications quickly in C++ without having to use GLUT. Hopefully, it will serve as a useful aid for similar projects.
If you do find any problems, or can suggest any enhancements or additions,
or even want to modify the source then please feel free. However,
I would request that any changes/additions you make be notified to me so
they can be included in future releases.
Last Updated: 27th April 2000