Intro to OpenGL and Tcl/Tk

  1. General introduction
  2. Introduction to OpenGL
  3. Programming examples 1 and 2
  4. Introduction to Tcl/Tk
  5. Programming examples 3, 4 and 5

Introduction to OpenGL

Your program calls OpenGL graphics functions, which access the graphics hardware for you.

So: OpenGL is hardware independent -> no user I/O (windows, mouse, etc.)

For user I/O we use Tcl/Tk. Also available: auxiliary library. On other systems it may for instance be Windows NT.

What do you do to get your picture on screen?

  1. Build models from points (vertices), lines, polygons (must be convex)
  2. Specify the scene: type of projection, position of viewpoint
  3. Specify whether shading, lighting, etc. should be used
  4. Send your data to OpenGL
You can also store your model data in a display list, and "execute" it later (Chapter 4 of the OpenGL Programming Guide).

Programming examples 1 and 2

All programming examples can be found in /u/cs426/Examples/Tcl+OpenGL/ex*.

Introduction to Tcl/Tk