There is an OpenGL example that comes with the DevC++ package, take a look at that.