Terrain rendering with C++ and OpenGL