Cogs.Core
NoiseSampler.h
1#pragma once
2
3#include <vector>
4
5#include <glm/glm.hpp>
6
7namespace Cogs
8{
9 namespace Core
10 {
12 {
13 public:
14 NoiseSampler(unsigned int seed = 42);
15
16 float gradNoise2D(glm::vec2 t, glm::ivec2 period);
17
19 void gradNoise2D(float* dst, float frequency, int w, int h);
20
21 void gradNoise2DSum(float* dst, float frequency_min, float frequency_max, int w, int h);
22
23 void gradNoise2DTurbulence(float* dst, float frequency_min, float frequency_max, int w, int h);
24
25 private:
26 std::vector<float> gradient2DTable;
27 std::vector<unsigned char> permutationTable;
28 };
29 } // namespace Core
30} // namespace Cogs
Contains all Cogs related functionality.
Definition: FieldSetter.h:23