• Advertisement
Sign in to follow this  

heightmaps and vbo's

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

If you intended to correct an error in the post then please contact us.

Recommended Posts

Greetings, i'm just wondering, what's the best way to set up heightmaps?

should i have a big grid vbo and transform it somehow(not sure how to do that), have  one instance of a plane VBO for each grid or simply build all the terrain once into a single VBO and perhaps rebuild it if i ever need to

 

anyways, anyways, i'd appreciate any suggestions, i'm still relatively new to using VBOs

Share this post


Link to post
Share on other sites
Advertisement

It all depends on what you are trying to achieve, But usually the best way to start is to have one VBO and multiple IBO that reference different part of the terrain, that way you can have multiple textures use on the same terrain and render all batch that uses the same texture. The other option is to have one IBO and one VBO and just use an Atlas, but i would not recomemend doing that for terrain as it becomes an hasstle when you trying to blend between tiles on the terrain. There are tons of way you can go about this and what i just mention is only scratching the surface.

Share this post


Link to post
Share on other sites

As said above, just use one VBO for the heightmap. This way your program code is looping less to render the heightmap. To assign different textures to the heightmap use a Texture3DArray. Just change the texture index z coordnate for the texture of that specific geometry.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement