Jump to content
  • Advertisement
Sign in to follow this  
Kaptein

Graph to terrain conversion

This topic is 366 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

Hey all, this is mostly a thinking problem.

I have terrains, all of which are placed on an N-dimensional graph/system which determines their wetness, temperature etc. The conversion from a biome coordinate/point to a terrain is done by simply  finding the closest terrain point/coordinate in the system. Think voronoi diagram. Given that there are very few terrains (lets say 20), shouldn't I just be iterating over each point and determine which is closest? What would you prefer?

I have implemented uniform voronoi cells myself for creating simple zones, but I feel like using a Voronoi diagram just for this is overcomplicating it.

Edited by Kaptein

Share this post


Link to post
Share on other sites
Advertisement

What do you need in a terrain?  Do you want a regular grid, as those are used in many engines, or do you want an irregular mesh? A TIN may work better for some purposes as they can potentially be smaller and easier to work with than a full grid mesh.

 

If you're looking to merge them into a regular grid, are you able render each area as a polygon on a plane? That kind of rasterization is probably easier than iterating over every point with each point requiring a new search of the graph.  Even if you had to render each of your twenty or so layers individually as polygon meshes and then merge them as a single linear pass, that would still likely be less processing work than searching the graph for every pixel in the image.

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!