How to generate biomes?

Started by
5 comments, last by AuthenticOwl 9 years ago
Hi,

I have a voxel based world in my game and I want to generate bioms (plains, forests, oceans, deserts etc.) and transitions between biomes (beaches, rivers etc.). I currently pick random points in the world and set them to a random biome and expand them random. But this only works if I generate the whole biome map at once. The world is not endless, it is more like a planet. You can walk from a point in any direction and if you continue walking, you will arrive at the point again and again and again and...

The current biome generation works for little planets (1024x1024 meters of surface), but the larger the planets get, the longer it takes to generate the biomes.

Is there an algorithm to generate a seamless biome map per chunk instead of all at once? I use 4D Perlin noise for height computation, but I was unable to generate a biome map like the one Minecraft generates using Perlin noise.
Advertisement

I'm not really clear on what problem you're having here. You describe what you're doing, but then you just say that you can't use Perlin noise. Why not?

If it's just that you don't want to wait for long map generation times, then maybe you could do the top-level noise, and then do the progressively lower levels of noise only as needed? Do one Perlin iteration for the whole map, then break it into segments. Do a Perlin iteration for the segment the player is in, then break it into smaller segments, etc. down to the level of detail that you want. Keep the final results stored and mark unprocessed areas so that you don't have to repeat the work later. If you put a little thought into how you break up the segments then you should be able to amortize the work pretty effectively.

void hurrrrrrrr() {__asm sub [ebp+4],5;}

There are ten kinds of people in this world: those who understand binary and those who don't.
The reason why I do not use Perlin noise for biome generation is not a technical one. The biomes just don't look like I want them to look when I use Perlin noise. I have no idea how to generate biome maps which look like the biome maps in Minecraft using Perlin noise. The biome borders should not be smooth curves, but I was unable to generate non-smooth biome borders with Perlin noise. And with Perlin noise, some biomes are really huge while others are tiny. I want the size of the biomes to vary a little bit, but not too much (big biomes are okay, but they shouldn't be too small).

Then learn how to use Perlin noise.

There are other algorithms out there.

Brownian noise and Fractal Brownian noise have been popular.

The old midpoint displacement fractal is easy to compute and usually looks pretty good as well, as long as you don't mind some square corners occasionally. The squares are probably not an issue in a grid-based world. This was very commonly used back in the '80s and '90s for both terrain and for plasma-style screen savers.

If you don't want smooth boundaries, add large amounts of dithering noise to the smooth (coarse scale) noise field to perturb cluster boundaries without changing (on average) the size of the clusters.

If you don't want small clusters, ensure the noise field doesn't contain high frequency components. The easiest way that comes to mind is using an inverse Fourier transform of perfectly band-limited source data.

Omae Wa Mou Shindeiru

I did a hybrid between all at once and chunks as needed. I created a planet wide geography map that contained the heightmap, a tempature map, a moisture map and a wind map... using the heightmap i was able to create the temp map f(lattitude,height)=temp
and using the windmap I was able to create a moisture map.

Then, with the moisture map and the temp map I created a function f(temp, moisture)=biome.

I used this graph : http://www.marietta.edu/~biol/biomes/whittaker.jpg

as the basis for the biome function.

Then, when creating the each cell in the high level map represented a 128x128 local map which was create procedurally as needed... when creating the local map I used a probability function weighted by distance to edge and biome at that edge to determine the specific biome of the specific local tile.

This topic is closed to new replies.

Advertisement