Jump to content

  • Log In with Google      Sign In   
  • Create Account


Looking for a good+solid implementation of TomF's vertex-cache-optimization algorithm


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 RenHoek   Members   -  Reputation: 119

Like
0Likes
Like

Posted 31 October 2012 - 04:01 AM

Hi all

I'm coding for modern CPU's.
But the meshes I'm sending to the graphics card are pretty much directly output from Maya. I guess they will have poor vertex-cache-ordering.
I'm hoping to use a vertex-cache-optimization pre-pass on the meshes to gain some performance. As suggested here
http://home.comcast.net/~tom_forsyth/papers/fast_vert_cache_opt.html

Does anyone know of the best technique to use on modern cards? Is it still Toms algorithm? The models I have to render have 1,000,000+ triangles. :(
So I would like the pre-pass to run fast, as well as produce good results. ( like Toms algorithm )

2nd Question.
Does anyone know of a solid and good implementation of Toms algorithm? The ones I'm finding on the internet seem to be from junior/hobby programmers who are not writing the most efficient code.

Thanks all
Ren

Sponsor:

#2 Ingenu   Members   -  Reputation: 813

Like
0Likes
Like

Posted 31 October 2012 - 04:04 AM

It's the best solution, AFAIR. See http://gameangst.com/?p=9

I think you can find code here: http://rosario3d.wordpress.com/2011/06/19/triangle-render-order-optimization/
(Not really read it, just did remember having seen it, I implemented it myself once it wasn't difficult.)

Edited by Ingenu, 31 October 2012 - 04:06 AM.

-* So many things to do, so little time to spend. *-

#3 MJP   Moderators   -  Reputation: 10281

Like
0Likes
Like

Posted 31 October 2012 - 12:10 PM

I used to use Tootle for mesh optimization, which is an older library from ATI. However they haven't updated it and there's no VS2010 version, so I stopped using it. The old D3DX mesh library can optimize for you, although I don't know what algorithm it uses.

Strictly speaking, an algorithm like TomF's is no longer the absolute best way to optimize for a high-end modern GPU. This is because newer GPU's have multiple hardware units for setting up triangles, which means triangles will get processed concurrently rather than in sequential order. But optimizing for this would require specific knowledge of how the hardware splits up triangles among its hardware units, so it's probably not practical unless you're targeting a specific GPU or family of GPU's. Either way you can still get gains out of the older optimization methods, so it's still worth doing.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS