Skip to main content

Module noise

Module noise 

Source
Expand description

Deterministic noise seed engine for fingerprint perturbation.

Provides NoiseSeed, NoiseEngine, and NoiseConfig for injecting repeatable, per-session noise into canvas, WebGL, audio, and layout APIs. Given the same NoiseSeed, all noise generators produce identical output across platforms and across Web Workers / Service Workers.

§Example

use stygian_browser::noise::{NoiseEngine, NoiseSeed};

let engine = NoiseEngine::new(NoiseSeed::from(42_u64));
let (dr, dg, db, da) = engine.pixel_noise("canvas.toDataURL", 10, 20);
assert!((-3..=3).contains(&dr));

Structs§

NoiseConfig
Configuration for the fingerprint noise subsystem.
NoiseEngine
Deterministic noise generator seeded with a NoiseSeed.
NoiseSeed
A 64-bit seed that drives all deterministic noise generators.