I am trying to "fill" a surface of a sphere that I drew using this algorithm here: http://paulbourke.net/miscellaneous/sphere_cylinder/, the first method.
I know that GL_QUADS
is no longer used in OpenGL 3+. SO I used GL_TRIANGLE_FAN
. Is it the same thing? The problem here is that my sphere facets are squares. So if I use GL_TRIANGLE
then I get a weird "filling", not all the surface is covered.
Am I doing it the wrong way? How does GL_TRIANGLE_FAN
work exactly?