Jump to content
  • Advertisement
Sign in to follow this  
Halsafar

"Noise" in content of games, 3D

This topic is 4732 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

What exactly does this mean when people refer to noise in context with things like noise textures, and noisemaps, or generating things based off of noise. I googled it but just found an array of stuff either about noise itself or some neat videos on for example: "Several concecated sphere's using noise" It looked amazing...

Share this post


Link to post
Share on other sites
Advertisement
"Noise" refers to a family of mathmetical functions with a set of specific properties. Noise functions are smooth, continuous, vary on a constrained interval (usually [0,1] or [-1,1]) and have the appearance of being "random." They are mainly useful when one needs some random-looking values, but they need to smoothly blend into each other.

Ken Perlin is recognized as the father of modern noise functions. He has a great presentation on how noise functions work and what they are useful for at Noisemachine.com. Perlin's original use for noise was to create interesting procedural textures for Tron. To date noise remains one of the primary methods for creating such textures, especially in conjunction with turbulence functions, which Perlin also covers in the presentation.

Share this post


Link to post
Share on other sites
You could take a look at some of the demos and examples done with the libnoise library. It includes a demo that is an entire planet (comparable to earth-sized) generated down to a 7.5 meter resolution; that is, any area of the planet's surface can be sampled at any resolution down to 7.5 meters. It was created simply by chaining together several noise generators as well as assorted other modifiers and selectors.

I've done a few simple articles about random level generation as part of a side project, including one about using noise as a turbulence generator for the elimination of obvious straight-line patterns in a generated level, here. There is also an article on the site by Squirm that uses simple fractal noise to determine the distribution of trees in forested areas, the placement of bodies of water, and so forth.

Basically, most techniques rely on a source of what is called 'continuous noise'. In this form of noise, samples are random but not completely random; ie, there is usually a very small difference between two samples that are very close together in the function, but there can be possibly a large difference between samples that are farther away. If you sample a perlin noise function into a heightmap or a greyscale image, adjacent values in the map will differ from each other only by small amounts, while values that are separated from each other by a greater distance can (but not necessarily will) differ by larger amounts. You can sample the noise in finer and finer increments, and the general 'path' or sample curve of the noise will stay close to the same. The finer the increments you sample, the less variation there is in adjacent samples.

Good continuous noise like Perlin noise, and it's associated variants, are popular methods for terrain heightmap generation just by themselves, but they can be even more useful in other ways or when combined together in complex transformations. The libnoise site details a technique called Perlin worms that uses a 3D perlin noise map to control the movement and wiggle of a bunch of worm-like objects; very cool, and kinda creepy as well. [grin] It also details other techniques for more complicated heightmap terrain generation than simply dumping a perlin noise into a height buffer; ie, using additional noise sources as selectors, blenders, etc...

The turbulence technique (explained in my article) can have a number of applications to such things as procedural texture generation. A common trick is to take the output of a 2-dimensional function that utilizes the sin() or cos() function to generate a banded pattern across the texture, and to perturb the input coordinates of this function with Perlin noise to achieve the chaotic, swirly veined marble effect that you see all over the place. Other uses may include generation of lava or wood-grain textures and so forth.

Some pretty interesting stuff can be done with it. If you're interested in playing with it, I highly recommend checking out libnoise or something like it.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!