prepare the basic opengl environment.