- Home /
Planetary perlin noise? My oceans are too patchy.
Hello,
I've been working on a simple planet generator. I currently create a spherical mesh using a random radius for each vertex. This creates a very patchy looking planet as follows:
I'm looking for a better algorithm of randomness. So I can have more 'planet' looking planets, or at least the option. I need bigger oceans, larger continents, basically just less patchy.
Anyone have any suggestions?
I don't have a definitive answer but here's what I can add: If you're using Perlin Noise, try doing multiple passes. After the first one, just randomize again, but on a smaller scale, just like Fractals, where it's recursive and repeats itself, while gradually beco$$anonymous$$g smaller and smaller. This will give a more definitive and less gloomy look, like real terrain.
Also if you want continents and oceans you're gonna need to define areas where the vertices' radius from the center is less random and more offset than others, either towards the center (ocean) or away from it (terrain).
In the end it all comes down to how random you want it to be, and how realistic, because creating an algorithm that could create earth-like planets that are completely random each time, would be very difficult.
Yeah, I pretty much need less random areas, and then strict borders between them. That's what I'm looking for.
Take a slower walk through the perlin noise to reduce the resolution of the bumps. You could also use a grayscale bitmap ins$$anonymous$$d of/in addition to the perlin noise. That way you could 'paint in' in the large continents.
But I would still like a procedural planet, what do you mean slower walk?
If you take a look at the example script for PerlinNoise() you will see:
var xCoord = xOrg + x / noiseTex.width * scale;
var yCoord = yOrg + y / noiseTex.height * scale;
The 'scale' changes how far to move for the next sample. If you move a smaller amount, you will move less on the 2D plane. It's like zoo$$anonymous$$g in on a part of the plane so you 'see' less bumps.
Answer by Kibsgaard · May 14, 2013 at 05:57 PM
Try having a look at this white paper: Generating Complex Procedural Terrains Using the GPU
Especially chapter 1.3.3 "Making an Interesting Density Function" and onward, where the Density Function is what you want to use as your "random depth" on your vertices. They explain everything very well and it should be no problem to use it just on the CPU.
Wow thanks, at a glance that seems very useful. I think that will probably suit me best for now. : )
That link not valid. This is probably the same thing: https://developer.nvidia.com/gpugems/GPUGems3/gpugems3_ch01.html
Answer by rdavid269 · Feb 12, 2015 at 03:52 PM
try the module: massive with a seed: 131.5054 and check how it will look
Your answer
![](https://koobas.hobune.stream/wayback/20220613102217im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
What is the best method to create a planet in Unity? 1 Answer
Is it possible to generate a high-poly spherical model from a mercator-projection heightmap? 1 Answer
Perlin Noise Spherical Terrain 2 Answers
'Planet' height based, Texture2D setPixel performance queries. 1 Answer
Perfomance Issue With Minecraft Clone. 0 Answers