Jump to content

Topographic Map


SiliconPyro

Recommended Posts

What would be the most efficient way to create a topographic display is KSP? The idea is that it would appear as a fixed camera looking directly downward. The important information is going to be presented on top of the topo lines, I just want them as a background, but I want them to be real.

For those who don't know, this is a topographic map:

Figure%2016.jpg

It occurred to me that I could generate a plane for each elevation increment, then LineRender wherever those planes intersect the terrain collider. Now just to figure out how to do that!

Edited by norcalairman
Link to comment
Share on other sites

Well, I used to use a mapping plugin to output the elevation data to a CSV file and then input it into Surfer 10 to make different types of maps, topographic being one of them. I haven't done that in a while though as the mapping plugin hasn't been updated to work with .23 as far as I know.

Link to comment
Share on other sites

the terrain is defined as pairs of rather large triangles which together form 'perfect squares' in a 2D sense with the vertexes raised or lowered to create the variance; the best way in my eyes would be the planar section method but instead of making a line render of the collision pattern, simply determine where triangular edges intersect the plane and draw lines between them, rather than sampling along the mesh more frequently than may be necessary. The hard part will likely be assembling the lines in the correct order. From there you would only need to determine the highest and lowest vertexes in the region you care about and distribute however many planes you want between them; if done correctly it should be a rather cheap check to run but the entire map may be expensive to compile.

Link to comment
Share on other sites

  • 3 weeks later...

You can either use the heightmap from the planetary shader, or use a z-depth pass to get the information in realtime. Zdepth would only work if the camera was perfectly perpendicular to the ground tho. I would recommend looking at the SCANSAT plugin to see how he does it.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...