Move from OpenGL 2 to OpenGL 3

This branch closes issue #3.