Jump to content
  • Advertisement
Sign in to follow this  
Quat

sorting by state techniques

This topic is 4698 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I have heard of a technique where you use 1 static vertex buffer for static geometry, and then build dynamic index buffers based on visibility and device state sorting. Is this technique worth it? This method seems good in that you can sort geometry by states easily, but won't it pretty much mess up any vertex cache reorganization opimization? Are there any other ways to sort and render geometry based on device states while still using static vertex buffers?

Share this post


Link to post
Share on other sites
Advertisement
Hi,

You could also create 1 big index buffer, and simply issue different DIP call (assuming you use DirectX ^^) with the corrects start indices, number of primitives, etc. (this way, no need to recreate the index buffer)

The problem with that is vertex formats. You can't have different vertex format in the same VB, so you need to create as many VB / IB as you have different vertex formats.

Or you could create lots of VB / IB. This way is a little less optimal (well, depending on scenes, it can be a LOT less optimal ^^) but you don't have to care about vertex format, etc. ^^

Share this post


Link to post
Share on other sites
If you use display lists in opengl, all your state changes are cached.
That way, you won't have to optimize state changes.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!