12 float sShiftX = sweepX * 0.005f + 0.007f;
13 float sShiftY = sweepY * 0.005f + 0.007f;
14 float sShiftZ = sweepZ * 0.005f + 0.007f;
28 return sNoise.GetRGB(position, normal, uvw);
A dynamic simplex noise gradient material for a lava lamp effect.
FunctionGenerator fGenMatGradientX
Function for x-axis modulation.
FunctionGenerator fGenMatGradientZ
Function for z-axis modulation.
Material * GetMaterial()
Retrieves the associated material.
float simplexNoiseDepth
Depth parameter for simplex noise.
RGBColor GetRGB(const Vector3D &position, const Vector3D &normal, const Vector3D &uvw) override
Computes the color at a given position using simplex noise.
FunctionGenerator fGenMatGradientY
Function for y-axis modulation.
RGBColor noiseSpectrum[2]
Gradient colors for the noise material.
void SetGradient(RGBColor color, uint8_t colorIndex)
Sets a specific gradient color.
GradientMaterial< 2 > gNoiseMat
Gradient material for simplex noise.
void Update(float ratio)
Updates the material's state based on the provided time ratio.
SimplexNoise< 2 > sNoise
Simplex noise generator.
FunctionGenerator fGenMatGradientP
Function for gradient property modulation.
Abstract base class for rendering materials.
Represents an RGB color and provides methods for manipulation.
Represents a 3D vector (X, Y, Z) and provides methods for vector arithmetic.