|
HighMap library (C++)
|
Array (x, y) function class. More...
#include <functions.hpp>
Public Member Functions | |
| float | operator() (float x, float y, float ctrl_param=0.f) const |
| ArrayFunction (Array array, glm::vec2 kw, bool periodic=true) | |
| Construct a new ArrayFunction object. | |
| void | set_array (Array new_array) |
| Set the array object. | |
Protected Attributes | |
| glm::vec2 | kw |
| Frequency scaling vector. | |
| bool | periodic |
| Flag indicating whether the domain is periodic or not. | |
Array (x, y) function class.
This class functions like an image sampler with normalized coordinates found on a GPU. It is based on a 2D array, allowing interpolation of any value at a given (x, y) coordinate. Specific boundary conditions, such as periodicity, can also be used.
| hmap::ArrayFunction::ArrayFunction | ( | hmap::Array | array, |
| glm::vec2 | kw, | ||
| bool | periodic = true ) |
Construct a new ArrayFunction object.
| array | Data array. |
| kw | Noise wavenumbers {kx, ky} for each direction, with respect to a unit domain. |
| periodic | Whether the domain is periodic or not. |
| float hmap::ArrayFunction::operator() | ( | float | x, |
| float | y, | ||
| float | ctrl_param = 0.f ) const |
|
inline |
Set the array object.
| new_array | New data array. |
|
protected |
Frequency scaling vector.
|
protected |
Flag indicating whether the domain is periodic or not.