stdlib/noiseView source ↗
noise
10 items · generated by scribe fromstdlib/noise.fd· synced 2026-11-15
Contents
noise2
Perlin noise at (x,y), roughly [-1,1]. Scale x,y by your feature size.
Example: println(float_to_str(noise2(1.5, 2.5, 42))); // same call, same output: noise is deterministic
pub fn noise2(x: f64, y: f64, seed: i64) -> f64 {Parameters:
x:f64y:f64seed:i64
Returns: f64
Defined at line 75
noise3
Perlin noise at (x,y,z), roughly [-1,1].
pub fn noise3(x: f64, y: f64, z: f64, seed: i64) -> f64 {Parameters:
x:f64y:f64z:f64seed:i64
Returns: f64
Defined at line 111
fbm2
fBm: oct octaves of noise2, each octave at 2x frequency and gain amplitude. lacunarity is fixed at 2.
pub fn fbm2(x: f64, y: f64, oct: i64, gain: f64, seed: i64) -> f64 {Parameters:
x:f64y:f64oct:i64gain:f64seed:i64
Returns: f64
Defined at line 138
fbm3
fBm 3D, same contract.
pub fn fbm3(x: f64, y: f64, z: f64, oct: i64, gain: f64, seed: i64) -> f64 {Parameters:
x:f64y:f64z:f64oct:i64gain:f64seed:i64
Returns: f64
Defined at line 158
poisson2
Poisson-disk points in a w x h rect with min spacing r. tries per active point (30 is standard). seed randomizes the start + picks.
pub fn poisson2(w: i64, h: i64, r: i64, tries: i64, seed: i64) -> Vec<i64> {Parameters:
w:i64h:i64r:i64tries:i64seed:i64
Returns: Vec<i64>
Defined at line 183
Generated by scribe, the Fides documentation generator