]> git.localhorst.tv Git - blobs.git/blob - src/rand/WorleyNoise.hpp
fix return value of tsr get double
[blobs.git] / src / rand / WorleyNoise.hpp
1 #ifndef BLOBS_RAND_WORLEYNOISE_HPP_
2 #define BLOBS_RAND_WORLEYNOISE_HPP_
3
4 #include "../graphics/glm.hpp"
5
6
7 namespace blobs {
8 namespace rand {
9
10 /// implementation of Worley noise (aka Cell or Voroni noise)
11 class WorleyNoise {
12
13 public:
14         explicit WorleyNoise(unsigned int seed) noexcept;
15
16         float operator ()(const glm::vec3 &) const noexcept;
17
18 private:
19         const unsigned int seed;
20         const int num_points;
21
22 };
23
24 }
25 }
26
27 #endif