How could I use cellular noise to generate biomes?

I’m working on world generation for my game. I wanted to generate biomes using the Unity.Mathematics.noise.cellular() method to have divided sections of land.

However, my current approach (taking the returned float and placing tiles based on the value) doesn’t really work. I understand why— the values that cellular noise returns look like this:


So if I’m placing biomes based on the values that get returned to me, I wont get biomes divided into certain cells, I’ll just get biomes placed on certain noise values.

My question is, how would I go about using the data that gets returned by the noise.cellular() method to divide biomes into chunks?

You probably need a filter to get patches from cellular noise. But check out this tutorial first:

https://www.redblobgames.com/x/2022-voronoi-maps-tutorial/

And take a look at my amazing zoo of shaders to get an idea on filters:

1 Like

this is cool, but necessarily what I want. The article still uses a hightmap to generate biomes, not voronoi noise.

Then hear my crazy idea: I think you can do it using filters instead of polygons, which is ultrafast and unneccessarily more memory wasteful, but fun. And fun is what we want. Right?

For visualization what you are trying to achieve is a stained glass effect. Each fragment is slightly more tinted than the ones next to it. Right?

Yeah, couldn’t I just write a custom cellular noise function for each chunk?

You could apply an edge detection filter to divide each chunk, then mask it out and apply other filters at lower scale to build the biome.