Auburn / FastNoiseLite

Fast Portable Noise Library - C# C++ C Java HLSL GLSL JavaScript Rust Go
http://auburn.github.io/FastNoiseLite/
MIT License
2.79k stars 327 forks source link

Possibility to generate periodic noise #20

Closed realisim closed 4 years ago

realisim commented 6 years ago

It would be nice if we could generate periodic (tileable) noise. Of course it does not apply to all noises, but Perlin and Cellular noise are good canditate.

Periodic noise should also work when they are used with the fractal pertubations (FBM or other).

Since not all noise are subject to periodicity, maybe a predicate in the form: bool CanBePeriodic(NoiseType iNoiseType) const;

and to mimic GetNoise function:

FN_DECIMAL GetPeriodicNoise(FN_DECIMAL x, FN_DECIMAL y);
FN_DECIMAL GetPeriodicNoise(FN_DECIMAL x, FN_DECIMAL y, FN_DECIMAL z);