Game Development Community

16-bit index buffers

by Andrew "Anger" · in Torque Game Engine Advanced · 03/22/2006 (9:04 am) · 4 replies

I 've just stumbled upon the limitation, that TSE GFX layer supports only 16-bit index buffers. Not that I'm complaining, however I couldn't think of a good reason, why not let the user decide, whether he wants to use 16 or 32-bit indices... Why this limitation?

#1
03/22/2006 (3:57 pm)
I think maybe it is because some older cards don't support 32 bit index buffers. You could support it and just put in checks for card support, but why bother. The only good reason to do this is if you have more than 65536 vertices in a single vertex buffer. I might be wrong about this but I don't think there are many rendering tasks that require so many vertices save maybe a few terrain implimentations. And besides, if somebody needs 32 bit buffers they got the source code they can add it if they need it.
#2
03/22/2006 (4:16 pm)
Well, I don't really think it's a support issue, because only really old cards don't support 32-bit index buffers, however TSE (at least in it's current state) won't even run on cards that don't have at least shader model 1.1 on em' (correct me if I'm wrong). And by the way, you said "65536 vertices in a single vertex buffer", which is wrong... :) It has nothing to do with the vertex buffer, but you can't have more than 65536 indices in an index buffer... ;)
#3
03/22/2006 (8:05 pm)
Umm, no you can have as many indices as memory allows. The same for vertex buffers. Perhaps i should rephrase myself. By "65536 vertices in a single vertex buffer" It mean that you can't reference more than 65536 different vertices in an a index buffer. Remember 32 & 16 are the size of the indices in the index buffers.
#4
03/23/2006 (2:25 am)
Whoa... sorry... You are totally right!! I feel so embarassed... I guess coding for 12 hours in a row degrades my logic... :)