OpenGLContext Documentation
This document collects OpenGLContext-specific
documentation. The main PyOpenGL
documentation collection includes links to both PyOpenGL and OpenGL
documentation which will be of use to the OpenGLContext programmer as
well.
OpenGLContext-Specific Documentation
There is little OpenGLContext-specific documentation at the moment.
The most useful items are probably the rendering process
description, and the pydoc-generated reference. The NeHe tutorial
translations should be useful for beginning OpenGL programmers.
- Tutorials --
Documentation for users unfamiliary with OpenGL, Shaders and the like,
includes the NeHe translations and the Introduction to Shaders tutorials
- The Rendering Process -- The
rendering algorithm(s), including the scenegraph traversal mechanism(s),
used by OpenGLContext when rendering a scene
- Using VRML97 -- Tutorial on using the
(partial) VRML97 loader and the nodes it creates
- OpenGLContext, ttfquery, and vrml pydoc -- Automatically generated
documentation for the OpenGLContext , ttfquery and vrml packages
- Structural Overview --
OpenGLContext's architecture and implementation
- Rendering Text -- Overview of the Text and
FontStyle scenegraph nodes, general notes regarding support of text in
OpenGLContext
- Using Numeric Python -- Overview
of using Numeric Python within OpenGLContext (and PyOpenGL), with
emphasis on the basics of Numeric Python, rather than PyOpenGL specifics.
- OpenGL pydoc -- automatically
generated documentation for the entire OpenGL package. Allows you to
browse, for example, the extensions current supported (e.g.
OpenGL.GL.ARB), and the functions wrapped
Sample Code (Where to Look)
The râison d'être (apologies for my rusty French) for OpenGLContext is to
provide a platform for testing and sample code, so you'll find a lot of
it lurking about in the project. In particular, you can find
sample code for:
- NURBs objects, including surfaces and curves, with trimming
(scenegraph/nurbs.py)
- Polygonal text
- scenegraph/text/toolsfont.py (font rendering using OpenGL)
- ttfquery package (font metadata and outline extraction)
- Polygonal text using WGL (roughly derived from NeHe tutorial
number 14) (scenegraph/tests/glprint.py)
- GLU polygon tessellation (scenegraph/polygontessellator.py)
- Polygon-sorting by screen depth (needed during transparent
rendering passes)
- Stencil-buffer-based shadow rendering (preliminary) (shadow
sub-package)
- Multi-texturing (tests/nehe6_multi.py)
- Saving buffers to disk (screen capture) (tests/saveimage.py)
- Select-buffer-based mouse interactions
(tests/selectrendermode*.py)
- Particle-systems (preliminary) (tests/particles_simple.py)
- Generic node-rendering code, including background, light and
viewpoint setup (rendervisitor.py)
- Viewpoint manipulations (including Logo-like
forward/backward/up/down/turn, and examine/orbit modes)
(viewplatform*.py)
- Various approaches to rendering simple geometry
(tests/glarrayelement, tests/gldrawarrays, tests/gldrawarrays_string,
tests/gldrawelements, tests/glinterleavedarrays, tests/glvertex)
- Partial implementations of many VRML97 nodes, including
IndexedFaceSet, IndexedLineSet, PointSet, Transform, Switch and
Background (scenegraph package)
- PIL-to-texture loading (texture.py)
- Display-list management code (displaylist.py)