- Home /
Procedural planet to sphere texture
I'm making a 4x space game. I have a procedurally generated galaxy with planets in 3D space. The view is above zero looking down 45 deg, the planets are on y-0 i.e 45 deg isometric. I procedurally generate the planet surfaces on a hex grid which can be viewed 2D / 2.5D when clicking on the planets, ala GalCiv etc by placing meshes for mountains, seas, forest and so on on the hex grid.
For realism, I'd like the textures of the planets when viewed from space to (at least roughly) mirror the view you get in the surface view. I'm struggling to think how this might be achieved in Unity.
I figure I could create a render texture after generating the planet's surface and store it on the users HD. This has a few problems though - taking up HD space and not mapping well to a sphere (unless I always make the poles a uniform colour, which doesn't look good as the rest of the surface is quite highly detailed).
Another idea would be to create many generic textures for the space view of roughly each type of planet generated (blue / green / large continent / archipelago etc) and select a texture which most closely fits the procedurally generated map at run time. As long as the same texture isn't used for planets close to each other and the user doesn't compare the 3D view with the 2D view to closely then hopefully they won't notice!
So, any other ideas of how this might be achieved? I'm not looking for code, just a brainstorm of how I might get a procedural 2D map to be represented on a 3D sphere, or at least create a convincing illusion.
Your answer
![](https://koobas.hobune.stream/wayback/20220612145920im_/https://answers.unity.com/themes/thub/images/avi.jpg)