Sign in to follow this  
Gazoo

Large quantities of independant dynamic triangles

Recommended Posts

Hey again, I have an issue regarding the rendering of "large" quantities of independant dynamic triangles I am unsure of. I've search around (partly on this forum) and found some options but am still sort of unsure of the benefits of them. As such, I hope nobody minds me asking some more :) Basically I need to display a "large" (10,000+, but preferrably even more 200,000+) number of independant (non-joined) dynamic (they're gonna move almost every frame) triangles on a flat surface. Basically they will represent some ai agents. As I've understood it, there are two ways of going about this, either display lists or VBO (Vertex Buffer Object). Perhaps more ways even? Anyway, I am not quite sure which would suit me as it seems its very situation independent and I've yet to understand which the two thrive best in. I've also read a bit about nvidia's "GL_NV_vertex_array_range", but if I am not mistaken, that seems to work only for triangle meshes which I can't use. After all - the agents aren't joined at the hips :). Oh - and I'm running on a fairly beastly machine - Core Duo 2 T6600 with a GeForce 7600... I'll take any advice :) In advance, you have my gratitude, Gazoo

Share this post


Link to post
Share on other sites
Display lists cannot be changed - only destroyed and re-created with new data. Destroying and re-creating a display list takes almost as much time as rendering it - so this is not an option.

I'd recommend using vertex arrays. (VBOs are an extension to vertex arrays, not a replacement)

Share this post


Link to post
Share on other sites
If the triangles themselves aren't actually changing, but just moving then you can use Display Lists, because you can use glTranslatef, glRotatef just as if calling the Display List was like drawing a primitive.

But that will only work if you're just moving the triangles, if their shape, colour or texture is changing then I'd go with VBO's.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this