Jump to content
  • Advertisement
Sign in to follow this  
jor1980

Optimize mesh to generate trianglestrip

This topic is 2036 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 needto transform a mesh based on trianglelist into a mesh based on trianglestrip, so i am trying to do it using Mesh.Optimize but i think that i haven´t obtain a mesh based on triangle strip.

 

here is my code:

 


cloneMesh.GenerateAdjacency(0.5f);
cloneMesh.ComputeNormals();
            
SlimDX.Direct3D9.Mesh meshOptimizada = cloneMesh.Optimize(SlimDX.Direct3D9.MeshOptimizeFlags.StripReorder);

 

 Is it possible to do what i want using slimdx?if it not How can i make this transformation?

Share this post


Link to post
Share on other sites
Advertisement

Indexed triangle lists are generally more efficient on modern hardware than triangle strips. See this thread for a good discussion on the same subject.

Share this post


Link to post
Share on other sites

I want triangle strip no because of efficience but because the file format over i want to import my mesh needs trianglestrip, so i need to create the strip from a trianglelist and i want to know if i can do it using some directx function, i tried it with mesh.optimize but i couldn´t do it, so i want to know if what i want is possible

Share this post


Link to post
Share on other sites

NVIDIA has a tool for that. It is pretty old though. It would convert your TriangleList to TriangleStrip for you. I tried looking for a link for you, but it seem that the tool is deprecated and no longer supported. I cannot even find a link to it. Also to answer your question as well, DirectX has no function in there that will convert from List to strip.

You will have to either find a tool that will do it for you or write one yourself.

Edited by BornToCode

Share this post


Link to post
Share on other sites

Nvtristrip is so slow, it's practically unusable on larger meshes.

 

The only reason to still use strips instead of lists is to save a bit of memory space. What's most important is the (optimal) ordering of triangles in a list/strip. Manually generating a strip based on what D3DX.OptimizeFaces and D3DX.OptimizeVertices output, should be fairly trivial.

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!