Jump to content
  • Advertisement
Sign in to follow this  
MePHyst0

Multiple index buffers

This topic is 4731 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 all, I have a quite old question about index buffers in D3D :) I'm using index buffers to render my geometry, a common issue is that sometimes a single vertex(more precisely, vertices on a same location in a 3D space) have different texture coordinate/normal. So we need more index buffers(tex coords,normals). I checked the forum and used google, and as I noticed the only way how to solve this is manually load a vertex buffer with proper data. I know that D3D uses an internal dynamic vertex buffer to combine index buffer with vertex buffer when rendering. Is there a way how to force D3D to do this with multiple index buffers(position,tex coord,normal)? thanks a lot in advance

Share this post


Link to post
Share on other sites
Advertisement
You wouldn't have to have multiple index buffers, just multiple coincident vertices, so that it draws as if the mesh is continuous but there is actually a "seam."

You might also be able to do something fancy involving multiple vertex streams.

Share this post


Link to post
Share on other sites
Quote:
Original post by Drakex
You might also be able to do something fancy involving multiple vertex streams.

If you're particularly worried about this, then I would also suggest you look into multiple vertex streams. This page might be of use to you, even though it's more about geometry instancing it does make mention of using multiple streams.

Bare in mind that the number of streams available is hardware/driver dependent - so if you're wanting to remain "backwards looking" then the traditional duplicate vertex information might still be the best option.

hth
Jack

Share this post


Link to post
Share on other sites
You only get one index buffer. You can have multiple streams but they all use the same index buffer. I've heard this will change in the future to support hardware instancing.

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!