15#include "../../Utils/Math/Vector2D.h"
16#include "../../Utils/Math/Vector3D.h"
28template<
size_t materialCount>
Base class for materials defining shading and rendering behavior.
Combines multiple materials with specified blending methods and opacities.
void SetMaterial(uint8_t index, Material *material)
Replaces a material at a specific index.
float opacity[materialCount]
Array of opacities for each material.
void SetOpacity(uint8_t index, float opacity)
Sets the opacity for a specific material.
uint8_t materialsAdded
Counter for added materials.
void SetMethod(uint8_t index, Method method)
Sets the blending method for a specific material.
RGBColor GetRGB(const Vector3D &position, const Vector3D &normal, const Vector3D &uvw) override
Calculates the resulting color by combining all materials.
Method method[materialCount]
Array of blending methods for each material.
void AddMaterial(Method method, Material *material, float opacity)
Adds a new material to the combination.
Material * materials[materialCount]
Array of pointers to materials.
CombineMaterial()
Constructs an empty CombineMaterial instance.
Abstract base class for rendering materials.
Method
Defines blending methods for combining colors.
Represents an RGB color and provides methods for manipulation.
Represents a 3D vector (X, Y, Z) and provides methods for vector arithmetic.