Sign in to follow this  
d07RiV

Triangle strips

Recommended Posts

How much optimization do triangle strips provide other than reducing the index buffer size? Do graphic cards use the fact that adjacent triangles in a strip share an edge and interpolate values on that edge once instead of twice? In other words, if I have a mesh with 2048 triangles, will I improve performance by rendering it as 32 strips of 64 triangles (with 2 degenerate triangles between adjacent strips)? Besides, since I want the engine to run on lower end machines and should optimize primarily for them, do older GPUs (including ones built into laptops) optimize triangle strips?

Share this post


Link to post
Share on other sites
You should get a gpu profiler and test everything, if you're concerned at all about performance

Triangle strips were great for reducing memory, but in reality indexed triangle lists can better utilize the post-transform cache if there is a good amount of vertex sharing, resulting in less calls to the vertex shader than triangle strips, and so are usually preferred.

Share this post


Link to post
Share on other sites
Triangle strips have not been the most optimal way to render geometry for quite some time. (we're talking back to geforce 3 or so), so I would not recommend it even for low end machines.

You will get better performance by running your indexed triangle list through an optimizer to improve the pre/post transform geometry cache hits by moving triangles that share verts closer to each other in the index list.

nvidia and ati both have libraries that can do this for you (nvtristrip, and tootle)

If you want to test it out, make a 1x1 viewport, and a million triangle mesh, and try it both ways.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this