VBO + octree + shaders ?

Started by
0 comments, last by zedzeek 17 years, 12 months ago
Hello all! I'm can't figure out how to sort this problem out. > I have to use an frustum-culled octree structure to render my geometry, BUT I have to use vertex arrays or VBO's (of course). How should I store data to make this possible and efficient? > I'm using several shaders to render my scene. I don't want to perform unneeded switches as it's killing performance. Right now I'm storing data according to the shader to use, and render all faces of one specific shader at the same time; and so on for all shaders. How could I combine my shaders with the octree and VBO? Thanks a lot for your help, it'll be greatly appreciated! HT
Advertisement
I'm using several shaders to render my scene. I don't want to perform unneeded switches as it's killing performance. Right now I'm storing data according to the shader to use, and render all faces of one specific shader at the same time; and so on for all shaders. How could I combine my shaders with the octree and VBO?

thats the way to do it.
at the start of each frame go through the meshes marking what is within the viewfrustum.
and then loop through all the materials if any meshs with this material are visable set the material + then draw all the meshes

This topic is closed to new replies.

Advertisement