Jump to content
  • Advertisement
Sign in to follow this  
indigox3

newbie question on ID3DXMesh::DrawSubsets

This topic is 4277 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

I've been using only this mesh class so far in learning direct x, and I'm a little confused by the DrawSubsets method. I understand what its for, but what if the effect associated with each subset takes in different types of stream data? For example, if I have a mesh divided into two subsets, where one subset requires 1 set of UVs but the other subset requires 2 sets of UVs. Using the ID3DXMesh class, it seems that the only option is to create the mesh with one big vertex stream that includes both UV sets, instead of multiple streams for each UV set?

Share this post


Link to post
Share on other sites
Advertisement
The current implementation of ID3DXMesh uses only a single stream so you'll have to store your data as a superset. I've not actually tried it, but from a quick look at ID3DX10Mesh it seems they've rolled both instancing and multi-streams into the implementation which is nice.

If you really need streams then rolling your own simplfied ID3DXMesh-like implementation isn't so difficult. The major downside is that it becomes more difficult to use the many D3DX functions that operate on mesh data...

hth
Jack

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!