Skip to main content

Infinite Scoped Deterministic Fractal Noise

Project description

NoiseMaker

Olsen Noise algorithm for infinite scoped deterministic fractal noise. The noise is deterministic so it's perfectly for tiling and returning to the same postion and having the same regenerated noise. The algorithm is infinite and scoped so only enough values as needed are generated.

from PIL import Image
from noisemaker import noise
Image.fromarray(noise((250, 100), (0, 0), transpose=True)).save("noise0.png")
Image.fromarray(noise((250, 100), (0, 100), transpose=True)).save("noise1.png")
Image.fromarray(noise((250, 100), (0, 200), transpose=True)).save("noise2.png")

The noise() algorithm requires only the first shape parameter. The transpose flag is to covert it into an image ready format.

Tiling

  • noise0
  • noise1
  • noise2

Note these are three different images. Simply adjacent in the requested space, so they stack.

Box Kernel (Default)

from noisemaker import noise
from PIL import Image
Image.fromarray(noise(500, 500, iteration=5)).save("noise-5.png")

noise-5

Gaussian Kernel

There is also a gaussian kernel availible, which is about a third the blur factor of the default box blur:

from noisemaker import noise, GAUSSIAN
from PIL import Image
Image.fromarray(noise((500, 500), iteration=5, kernel=GAUSSIAN)).save("noise-5g.png")

noise-5g

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

noisemaker-0.0.1.tar.gz (3.0 kB view hashes)

Uploaded Source

Built Distribution

noisemaker-0.0.1-py2.py3-none-any.whl (3.0 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page