Is there any way to use surface normals while using the glDrawElements function.
When using glDrawElements, vertex normals are used instead of surface normals.
glNormal can be used but this requires a call to glDrawArrays for every triangle instead of one single call to glDrawElements.
With the present API, you would simply replicate the surface normals into each triangle vertex. While seemingly an inefficiency, it's actually faster this way when the API is implemented in hardware. You convert your model from a triangle soup into a set of triangle strips to make up for this.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.