I’ve inherited a project using some pretty old OpenGL code. I haven’t really used OpenGL in a while nor did I ever use it in a production environment. It’s a 3D visualization program and its performance leaves a lot to be desired. I’ve tried running the project using gDEBugger but I’m a bit stumped as to what I’m seeing.
It appears that the program is using a lot of deprecated functionality. gDEBugger is saying that 78.13% of calls are to deprecated functions (yay?). Of those I’m seeing things like glVertex3d, glNormal3f, glVertex2d near the top in terms of calls. These seem to be being called by things like gluCylinder and the like. In school we learned to use glBegin/end with shapes from glu. It seems that nowadays it’s prefered to use vertex buffer arrays.
The vertex batches section in gDEBugger is telling me that 99% of my batches are made up of 1 vertex. I’m assuming this has to do with the glu functions. I understand that using larger vertex batches would be preferred.
Should I consider rewriting all the opengl code to use vertex batches, drawing all the shapes manually this way? Or is there a way to use the glu functions with vertex batches?