Jump to content

  • Log In with Google      Sign In   
  • Create Account

heightmaps and vbo's


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 Ussyless   Members   -  Reputation: 142

Like
0Likes
Like

Posted 16 June 2013 - 09:10 AM

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



Sponsor:

#2 BornToCode   Members   -  Reputation: 927

Like
0Likes
Like

Posted 16 June 2013 - 10:55 AM

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.



#3 martyj2009   Members   -  Reputation: 114

Like
0Likes
Like

Posted 16 June 2013 - 08:38 PM

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.






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS