[quote]Ok, I understand now Tom. It’s amazing that there isn’t something better…six calls to glDrawRangeElements() to draw one stupid box!
In a real scene do people do something like this?
-
Bind woodTexture
-
Draw all polys that use woodTexture
-
Bind rockTexture
-
Draw all polys that use rockTexture
etc…
But in that case, you would have to have the polygons sorted for draw order by the texture they use, and that sounds odd.
[/quote]
Yup, thats how its done. Usually though, if you have a more complex model, where the texture changes very often, you rather have one texture that has all the different “paintings” and appropriate tex-coords to get the desired effect.
Current graphics accelerators couldn’t be this fast, I they couldn’t pipeline the vertex and fragment processing because the texture-loading between vertices with different textures would be way to costly.
Greetings,
Jan