Quake 3 rendering

Is there anyone knowing how quake3 engine render 99% of what is seen on the screen in only one glDrawElements… I mean how could this be possible considering every primitives does’nt have the same texture… I’ve saw this info on my quake 3 console and on this page…
http://www.gamers.org/dEngine/quake3/johnc_glopt.html

Is there anykind of glTexureObjectNamePointer
… or some extension that change the texturing state while glDrawElement is working?

[This message has been edited by Gabriel (edited 05-29-2000).]

You are misreading what is being said. “During gameplay, 99.9% of all primitives go through a single API point” What he is saying is that everything that gets drawn goes through the glDrawElements function call, not thats its all drawn in one function call.

Nate http://nate.scuzzy.net

Yes, I know but in quake 3 console it is written:

rendering primitive : single glDrawElements

If this is not want I think it is, what thats suppose to mean?

What I think they do is :

  1. Get the visible surfaces.

  2. Sort those visible surfaces by texture(and probably other quantity).

  3. The number of different texture(X) will be number of glDrawElements you’ll have to do.

  4. Execute the rendering pipeline X times changing the vertices every time.

Thank you all.