PDA

View Full Version : VBOs and binding multiple times



02-17-2004, 10:09 PM
Say you have a vertex buffer object containing 300 vertices, and you have 100 faces which access this vertex object, each sorted by a material ID (say, 10 different materials). If I bind the vertex object 10 different times (for the 10 different materials) during a frame, will this be a severe performance hit? Will it go and transform the vertex buffer object each of the 10 times? Or is it safe to use it like this?

Relic
02-18-2004, 03:57 AM
Binding doesn't mean transforming, it sets the base address of the data.
The start address is associated with gl..Pointer and the call to the drawing function (glDrawElements etc.) finally tells OpenGL which of the data in the arrays to use.