#ifndef GRADIENT_H #define GRADIENT_H #include #include "Color.h" #include #include class Gradient { std::vector> colors; float max; public: Gradient(); void addColor(RGBColor c, float value); RGBColor get(float x) const; private: static RGBColor lerpColors(RGBColor a, RGBColor b, float val); std::tuple getNeighbors(float x) const; }; #endif // GRADIENT_H