Jump to content
  • Advertisement
Sign in to follow this  
lucky6969b

Controlling Subsets' Material IDs

This topic is 415 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 split up the mesh into subsets. The final product as 116 subsets, I notice 2 or more faces could be merged into one subset, and render in one batch. How do I control the Material IDs,

The scenario is I need to create 116 materials as after-product if there is 116 subsets generated.

I look up the material by the attribute table's attribId, but the ids scatter around, for example, the first subset attrib id is 0 and the next is 60

Should I make up another level of lookups, say attrib id 0 and 60 goes to material slot 0 and atrrib id 1,2,3,61  go to slot 1?

 

https://www.mvps.org/directx/articles/mesh_subset.htm

The picture shows everybody maps to subset 0

The function still returns 116 subsets rather than 1

Thanks

Jack

2017_07_31_14_15_08_TestSB.png

Edited by lucky6969b

Share this post


Link to post
Share on other sites
Advertisement
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!