OpenGL GUI library for games
The library is no longer maintained due to a lack of time. The downloads and articles are still available for reference. Feel free to fork or otherwise use the source code and articles (please let me know if you do so, I would love to know where it ends up.)
Introduction
This is a Graphical User Interface (GUI) library for prototyping and building game user interfaces. It is based on OpenGL and written in (portable) C++. The library is completely free and open-source. Other features include:
-
widgets such as buttons, scrollbars, menuitems, textfields, etc.
-
ability to modify and create custom themes
-
can be used as an in-game texture (see UITest in the demo's)
-
API similar to Java Swing API
-
BSD license on source code.
Latest news
Mac OS X update
2006-07-18
There were some small problems with the .framework OS X release. Thanks to Jeffrey Wilcke these have now been fixed. As a bonus, I have also tested the library under Microsoft Visual C++ 2005 Express (free and highly recommended) and fixed some other small things. The new release can be found in the download sidebar.
Mac OS X port and maintenance release
2006-07-02
I've uploaded a new version of the library, which includes a port to Mac OS X. The source distribution includes a XCode project file as well as several bug fixes and a new theme. This new theme, although unfinished at this time, should make it easier to write custom themes. There is also a precompiled Mac OS X .framework distribution. The demo applications have not yet been ported, so they only work in Windows (for now).
Articles and documentation
Here are some articles, notes and documentation on the GUI library.
API
API documentation generated from the source code. Updated with each new release.
Getting started
This article describes everything from downloading and installing to creating your first OpenGL GUI. In short; everything you need to get started.
Writing a font engine
Because the library does not come with a standard font engine, this article will explain to you how to write your own font engine for use with the library.
How selection works
This article will describe how the selection of Components works. There are several ways of accomplishing the selection of items on a computer screen and in this article, three such methods are discussed and compared for their suitability within the library. This article assumes you have some understanding of how the Component hierarchy works and some basic OpenGL knowledge.
Code conventions
This document describes the programming style I used while writing the library. I did not write it to talk you or anyone else into using it (although that would be nice.) It could come in handy if you're interested in writing your own Components and contributing to the project, although you're of course free to use whatever coding convention you see fit. In the end, I don't really care what you use, as long as you use it consistently.
A note on memory management
This note describes the memory ownership policy used in the library, and why this particular ownership policy was chosen.
Creating an OpenGL component
A step by step tutorial of how to create an OpenGL component inside the GUI.
Not what you're looking for?
That happens. Here are some alternative OpenGL GUI libraries (in no particular order):
-
http://glgooey.sourceforge.net/ - GLGooey
-
http://turska.sourceforge.net/ - Turska
-
http://glam.sourceforge.net/ - GLAM
-
http://glui.sourceforge.net/ - GLUI
-
http://libufo.sourceforge.net/ - LibUFO
-
http://www.cegui.org.uk/ - Crazy Eddie's GUI system
Credits
Thanks to: Jeffrey Wilcke (Mac OS X help).