Skip to main content

Module noise

Module noise 

Source
Expand description

Noise functions for the Proof Engine mathematical renderer.

Implementations: Perlin 1-D / 2-D / 3-D, Simplex 2-D / 3-D, Cellular / Worley, Curl (divergence-free), Domain Warping, Ridged Multifractal, Billow, and Fractional Brownian Motion over each. All functions are stateless, deterministic, and seeded by a compile-time permutation table.

Functions§

animated_noise
Animated noise — samples a moving “slice” through 3-D space. time advances the z coordinate, giving smooth noise animation.
billow
Billow noise — absolute-value fBm, gives cloud and pillow shapes. Output ≈ [-1, 1].
curl2
2-D curl noise. Returns a velocity vector tangent to the gradient of the underlying Perlin field — zero divergence means no sources/sinks.
curl3
3-D curl noise — divergence-free velocity field in 3-D. Uses three separate Perlin potentials for the three curl components.
curl2_fbm
2-D curl noise with fBm underneath — richer turbulent flows.
domain_warp
Domain-warped fBm — feeds noise output back into coordinates. Produces the swirling, self-similar patterns seen in marble, flame, and procedural nebulae. warp_strength controls how much to offset coordinates.
domain_warp2
Two-level domain warp — deeper self-similarity, heavier compute cost.
domain_warp3
3-D domain warp.
fbm
Classic 2-D fBm over Perlin noise.
fbm1
1-D fBm over Perlin noise — useful for audio modulation and time curves.
fbm3
3-D fBm over Perlin noise.
fbm_simplex
2-D fBm over Simplex noise — tighter, more crystalline features.
from_01
Remap from [0, 1] to [-1, 1].
gradient_2d
Generate a gradient field direction from noise — useful for steering particles.
gradient_3d
Generate a 3-D gradient vector from noise.
noise1
1-D value noise (smooth random walk), good for audio modulation.
perlin1
1-D Perlin noise. Output ≈ [-1, 1].
perlin2
2-D Perlin noise. Output ≈ [-1, 1].
perlin3
3-D Perlin noise. Output ≈ [-1, 1].
quick_noise
Smooth noise at a position with no configuration — sensible defaults. Output in [0, 1].
ridged
Ridged multifractal — sharp ridges, excellent for lightning, cracks, and mountain terrain. Output ≈ [0, 1].
ridged3
Ridged 3-D variant — useful for volumetric density fields.
sample3
Sample 3-D Perlin noise at a world position.
sample_curl3
Sample curl noise at a 3-D world position.
sample_fbm3
Sample 3-D fBm at a world position.
simplex2
2-D Simplex noise. Output ≈ [-1, 1]. Sharper features than Perlin.
simplex3
3-D Simplex noise. Output ≈ [-1, 1].
tiled_perlin2
Tiled 2-D Perlin noise — wraps seamlessly at (tile_w, tile_h). Useful for seamless texture generation.
to_01
Remap from Perlin’s [-1, 1] to [0, 1].
turbulence
2-D turbulence — classic signed-to-abs fBm, used for marble veining.
turbulence1
1-D turbulence (abs fBm) — good for entropy ripple and heat haze.
worley2
Cellular / Worley noise. Returns (f1, f2) — distances to nearest and second-nearest cell point.
worley3
3-D Worley noise.
worley_crackle
f2 - f1 — highlights cell borders, useful for vein / crack patterns.
worley_f1
Nearest-cell Worley, clamped to [0, 1].
worley_fbm
Worley fBm — octave-stacked cellular noise for complex surface patterns.