Dynamic Instancing

Started by
3 comments, last by HyDr0x 12 years, 8 months ago
Hi folks,
well, I'd like to know whether dynamic instancing is worth the higher effort or not. I refer to the GPU Gems 2 article about that, if I understand it, they are saying that I must skin the geometry by the CPU before streaming the vertices to the GPU. Is that right? If so, isn't it more complex to do all those transformations? I mean I have something about 300 to 1000 vertices per skinned mesh and im drawing like 1000 or more of them. this results in aproximately 1000 draw calls. If i would pack them all into one single vertexbuffer, would this cause in higher framerates? I've done a small test and drawed 2000 of those small meshes and got 38 FPS with ~900.000 Polygons and my CPU was to 100% busy (task manager). When I looked away (I've done culling) I had 60 FPS and my CPU was only to ~50% busy. So I think it dynamic instancing could reduce this. I also rendered a more complex mesh ~3900 poylgons ~448 times. So I had ~8M polygons with 50 FPS. Those numbers are telling me that i should batch my geometry much more. But on the other hand I've made a simple test transforming some matrices for all those models and the framerate dropped down to 20. Should I use multithreading? Or is my idea of dynamic instancing totaly wrong? Oh and sorry for my english >.<
Advertisement
With modern hardware and API's you can instance skin meshes in a few ways, with no need to do any skinning or transformations on the CPU. What hardware and API are you using right now?
I'm using XNA with DirectX9, and I think thats the problem because all what I heard is that DirectX9 isn't as good as DirectX10 in sampling textures in the vertex shader. So I think that for example pallete skinning ( I refer to the Skinned Instancing white paper from nvidia) isn't working very good on it.
You can still sample textures in a vertex shader in DX9, it was just slow on DX9 GPU's. If you have any GPU that supports DX10 or higher, you can use textures in a vertex shader and it will be fast.
Ah, okay, that makes sense. I wasn't sure about this. So thank you for bringing me some clarity. Now I'll have to test which is faster, CPU multithreading or GPU palette Skinning :-)

This topic is closed to new replies.

Advertisement