Reusing VBOs (or lists)

Started by
1 comment, last by carloscruz 11 years, 5 months ago
TOPIC IMPLICITLY CLOSED WHILE I STUDY TRANSFORMATION MATRICES - THANKS


--------------

Ok, short:

[color=#006400]I would like to render trees. Fast. Using geometry + textures.

[color=#b22222]How to do that without making a single model in VBO or other list and trying to reuse that over a heightmap?

First question: I don't know how ([color=#ff0000]and I have already searched) to take a fixed geometry stored in fast memory and repaint that in another place for reuse. I mean: take a tree and draw it at x,y,z and at x+5, y+2, z+1 since the global position of the vertexes are already set IN THE MEMORY of the VBO.

If I can do the above, the problem could be easily resolved by[color=#0000cd] breaking down the possible variations of trunks, leaves and geometry of the trees and reusing those and those textures everytime, saving a whole world of memory.


How can I do that, may someone help me?


[color=#000000]If you want to answer just one question:
[color=#000000]Can I redraw a VBO at a relative position?


Thank you very much.
Advertisement
As far as I understand... you dont want to bind VBO once and render it several times but render it also once with multiple output meshes
Technique you are looking for is called geometry instanceing
check this:
http://http.developer.nvidia.com/GPUGems2/gpugems2_chapter03.html
But there are several things to check before using it
OpenGL 3.2 / Geometry shader support
For GLSL version try this:
http://www.geeks3d.com/20111111/simple-introduction-to-geometry-shaders-glsl-opengl-tutorial-part1/
Thank you very much. I'll take a look and study that.

This topic is closed to new replies.

Advertisement