Compiling OpenGL Outside the Lab
You are allowed to develop code on your own machine, instead of the
lab machines. However, you must ensure that your code compiles and
runs on the lab machines for grading (with the exception of the final
project). You must do this before the project is due, don't put it off
until the last minute!
Note that it is up to you to configure your home machine so that it
works. To make your lives a bit easier, we're providing the
information based on the experience of past students. If you have
additions or corrections, let us know.
OpenGL should be default-installed on everything (Linux/Windows/Macs).
You will need to install GLUT yourself on Windows and Linux.
- Windows:
- Macs:
- GLUT should already be installed on your Mac, as described
here.
- The only code difference on the Mac is the #include statement
for GLUT, which makes portability a one-line-change operation. Change
#include <GL/glut.h> to #include <GLUT/glut.h>
- To work from the command line, you will just need to modify your
Makefile. Change the -lGL -lGLU -lglut flags to -framework GLUT
-framework OpenGL -framework Foundation.
- Instructions for using XCode: http://www.vis.uky.edu/~dnister/Teaching/CS535/macNotes.html.
Or another Glut/Xcode tutorial, with pictures, at http://onesadcookie.com/Tutorials
- Linux:
See also the detailed instructions from USC.
Back to 314
Last modified: Wed Jan 20 21:38:53 PST 2010