Jump to content
  • Advertisement
Sign in to follow this  
RavNaz

X Animation performance with setTexture...

This topic is 4878 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 Guyz, So I've my animated mesh using Xfiles, no probs....however..:-) currently when rendering multiple animations of the same object, my code loops through all of the sub-sets of the first object, renders, then moves onto the next object and so on.... now the problem with this is that it's thrashing the SetTexture() calls, as for each object it's calling SetTexture numerous times...not good! So now what I'm trying to do is organise the renders, so that I render all objects that reference the same texture in one go: e.g. SetTexture(0, sometexture ) for ( int i = 0 to 10 ) RenderAllObjects() Is this the correct way to go?? Also how would I do this if the animated meshe's had more than one texture?? Is it SetTexture( X, sometexture1 )?? One more question before I go :-0 Each object is loaded individually, so each object has a mesh/hierarchy and it's own animcontroller.......how can I make it so that the object(s) share mesh/hierarchies?? I'm not using VS/PS as I dont have a decent card and want the code working on lower spec cards....... Anyone help?? Nice one!!!

Share this post


Link to post
Share on other sites
Advertisement
SetTexture(0, sometexture )
for ( int i = 0 to 10 )
{
SetTexture(1, sometexture )
RenderAllObjects()
}





if multiple animation sets used for same model, then put sets in a .X file.

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!