
636 VII Software Design
OpenGL(1.0–4.2) OpenGL ES(1.0/2.0)
OS X desktop GLUT, QT, wxWidgets, X11 QT
iOS embedded N/A CoreAnimation (iOS 2.0/3.0)
SGI desktop GLUT, QT, X11 EGL
Windows desktop GLUT, QT, wxWidgets, EGL EGL
Windows embedded N/A EGL, QT
Unix desktop GLUT, QT, wxWidgets, EGL EGL
Linux desktop GLUT, QT, wxWidgets, X11, EGL EGL
Linux embedded N/A EGL/QT
Android embedded N/A Android (1.0/2.2), EGL
Symbian embedded N/A EGL, QT
Blackberry embedded N/A BlackberryOS (5.0/7.0)
Web browsers N/A WebGL (ES2.0 only)
Table 44.1. Overview of the main OpenGL implementations on the various platforms.
As a demonstration, we show how to implement a very minimalistic OpenGL
program on a subset of all the possible platforms, as can be seen in Table 44.2.
For the sake of simplicity, we further limit ourselves to considering only APIs that
interface the creation of the so-called OpenGL drawing context, which specifies to
the operating system how a pixel is to be drawn to the screen. See [OpenGL 11] for
a more extensive discussion of this topic.
In describing the use of our selection of APIs on the subset of platforms, we
draw from the experience of writing the RenderTools [RenderTools 11] software li-
brary. The library was created over the course of the past three years (2008–2011)
to serve as a code base to create any conceivable OpenGL application on many dif-
ferent platforms. We tried to keep the classes lightweight: the library, in its sim-
plest form, depends as little as possible on external libraries. We used the whim-
sically named Extension Wrangler Library, or GLEW [Sourceforge 11], to manage
the various OpenGL extensions on each platform. Many deprecated math func-
OpenGL1.0–4.2 OpenGL ES 1.0–2.0
iOS N/A CoreAnimation(iOS 2.0/3.0)
Windows GLUT, QT, EGL EGL
OS X GLUT, QT N/A
Table 44.2. The selection of APIs and subset of platforms used in this article.