Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17560

Vertex buffer(s)

$
0
0

Hi forum!

 

While reversing one program, I found that it uses separate vertex buffers in combination with index buffer:

  • vb0 = Positions (always used)
  • vb1 = Normals (always used)
  • vb2 = UV (used only in high quality)
  • Index buffer

 

The only explanation I have: for some conditions (like don’t use UV), they simply don’t pass one of the buffer to the shader.

So, in low quality, GPU memory usage is lower.

 

Questions:

  1. Is there any benefit of separation positions and normals, if they are used in all circumstances?
  2. If all buffers are used in a shader, are there any benefits of using several buffers instead of one, that contains all data for one vertex?

 

Thanks in advance!


Viewing all articles
Browse latest Browse all 17560

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>