New answers tagged

2

This sounds like a technique similar to the one Giliam de Carpentier describes in his "Swiss Turbulence" example in this article: Normally, lots of material on the surface of mountains gets displaced from the peaks to the valleys over time, carving gulleys on its slopes and smoothing the valleys below. ... To smoothen the valleys, the algorithm ...


1

You can just play with the code to get a feel for how this term affects the output. Here I've made a Shadertoy using a piece of Inigo Quilez's code with two extra parameters added to the terrain function: float terrainH( in vec2 x, int o, float e) { vec2 p = x*0.003/SC; float a = 0.0; float b = 1.0; vec2 d = vec2(0.0); for( int i=...


1

Looks like your domain warping amplitude is just too small. Crank up your q to about 20x its current value and you'll get very pronounced domain warping: I made this image by modifying your code to replact the 4.0* with 80.0*: function pattern(x, y, scale, octaves, lacunarity, gain){ var q = [ fbm(x, y, scale, octaves, lacunarity, gain), ...


1

The derivative of a function gives you the slope at each point of said function (it actually gives you the rate of change, but the two are identical for the first derivative) For instance if you have the function \$f(x)=x\$, the derivative would be \$f'(x)=1\$, since the slope of the function is 1 at every point. Similarly for \$g(x)=x^2\$ it would be \$g'(...


10

Not with noise alone. The other answer is correct, you overlay several octaves of noise to get a realistic structure. But you need to bring in physics as well or it won't be a result resembling reality. The first approach is to add an erosion model. There's a lot of good sources for how to do that available. This will create ridges and channels in your ...


32

It looks like you're looking for "Turbulence", "Fractional Brownian Motion", or something similar. This is where we take multiple samples of the noise at different scales - like the different panes in your first image - and add them together. Each noise sample is commonly called an "octave". For each octave we add, we sample at a higher frequency (so the ...


0

Use a maze generation algorithm Use a modified form of Prim's Algorithm to create a basic maze of 20 rooms or so. Choose two rooms to be start and end rooms, ensuring the end is always reachable. Block off random doors with different door types and randomly add doors where two adjacent rooms are not connected (with low probability)


Top 50 recent answers are included