Vbo

VBO support has been added to Trimeshes. All you need to do is call the setVBO***Enabled that you desire. I’ve only tested having them all on or off. Also, if your card does not support them, it will fall back to regular arrays. TerrainBlock has it on by default.

I’m considering ditching the ability to enable partial VBO use. IE, get rid of setVBO***Enabled methods and replace them with just setVBOEnabled. Also, I’d like to switch to using drawRangedElements.



Any comments, thoughts on this change?

If the VBO code checks for card compatability underlying in the code, then why have set*() at all? Just always assume that the user would want to use it if the card supports it.

"guurk" wrote:
Just always assume that the user would want to use it if the card supports it.

While this may be true for a release version, I'd prefer to have the ability to enable/disable the feature at will for debugging purposes. You need to evaluate performance both with and without VBO. Also consider that the hardware may incorrectly report supporting VBO, so you'd need to disable it in software. I'm in favour of retaining the setVBOEnabled() method.

Right, I’d like to not assume use of VBO because it actually (according to nvidia and ati) can have a negative affect when used with fewer triangles (like < 100) Perhaps auto-enabling based on tri count might make sense, but being able to disable for debugging would also be useful. Thoughts?

"renanse" wrote:
Right, I'd like to not assume use of VBO because it actually (according to nvidia and ati) can have a negative affect when used with fewer triangles (like < 100).

Acccording to some benchmarks I've made and using the last driver set, using VBO's for little geometry won't change the framerate. It won't be slower or faster (tested on ATI and nVidia).

Perhaps auto-enabling based on tri count might make sense, but being able to disable for debugging would also be useful. Thoughts?


I think EricTheRed is right : we should have a full control of VBOs and have the ability to enable/disable them. But it's just a personnal thought... ;)
"Chman" wrote:
"renanse" wrote:
Right, I'd like to not assume use of VBO because it actually (according to nvidia and ati) can have a negative affect when used with fewer triangles (like < 100).

Acccording to some benchmarks I've made and using the last driver set, using VBO's for little geometry won't change the framerate. It won't be slower or faster (tested on ATI and nVidia).

This was based on performance presentations at the last GDC by both companies, so I assume they know what they are talking about for general rules of thumb.

Deal! I kind of figured that would be the answer, I guess I’ll just put the autocheck into my stuff. I actually agree, from a developer standpoint you always like to have control over as much as possible while still being able to get things done quickly. From a user standpoint, take as much control out of their hands… they’ll just ask, “What’s VBO for?”