# problem using VBO's and vertex arrays at the same time

This topic is 5413 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hi guys! I'm having a problem with my game engine.. for the terrain rendering, I hold the vertices in VBO's, now i wanted to use some vertex arrays for dynamic data but it didn't work. The triangles or whatever i rendered looked very strange. After hours of debugging I deactivated all the vertex buffer object things (creation and rendering) and now the vertex arrays are working as expected. Do I somehow have to deactivate the vbo's while rendering vertex arrays? I couldn't find anything related.. so I'm asking you guys :) Does anybody have an idea? Thanks a lot! misto

##### Share on other sites
Quote:
 Original post by mistoHi guys!I'm having a problem with my game engine.. for the terrain rendering, I hold the vertices in VBO's, now i wanted to use some vertex arrays for dynamic data but it didn't work. The triangles or whatever i rendered looked very strange. After hours of debugging I deactivated all the vertex buffer object things (creation and rendering) and now the vertex arrays are working as expected. Do I somehow have to deactivate the vbo's while rendering vertex arrays? I couldn't find anything related.. so I'm asking you guys :) Does anybody have an idea? Thanks a lot!misto

you are probably missing this, set the ptrs to NULL when doing regular VA's

glBindBufferARB(GL_ARRAY_BUFFER_ARB, 0);glBindBufferARB(GL_ELEMENT_ARRAY_BUFFER_ARB, 0);

Hope that helped

##### Share on other sites
Yes, that did it :) I really didn't knew that.. thanks a lot!!

##### Share on other sites
Nv gl specs have some vbo code examples in arb_vbo section. I think gl specs should include them at the end or something.

##### Share on other sites
they do... if they cover that example or not is another matter, but even if they dont its covered in the spec text for sure...

• 18
• 29
• 11
• 21
• 16