Class for performing a linear interpolation between colors.
More...
#include <dye.h>
|
| DyePalette (const std::string &description) |
| Creates a palette based on the given string.
|
|
void | getColor (int intensity, int color[3]) const |
| Gets a pixel color depending on its intensity.
|
|
void | getColor (double intensity, int color[3]) const |
| Gets a pixel color depending on its intensity.
|
|
Class for performing a linear interpolation between colors.
Definition at line 30 of file dye.h.
◆ DyePalette()
DyePalette::DyePalette |
( |
const std::string & |
description | ) |
|
Creates a palette based on the given string.
The string is either a file name or a sequence of hexadecimal RGB values separated by ',' and starting with '#'.
Definition at line 29 of file dye.cpp.
◆ getColor() [1/2]
void DyePalette::getColor |
( |
double |
intensity, |
|
|
int |
color[3] |
|
) |
| const |
Gets a pixel color depending on its intensity.
Definition at line 134 of file dye.cpp.
◆ getColor() [2/2]
void DyePalette::getColor |
( |
int |
intensity, |
|
|
int |
color[3] |
|
) |
| const |
Gets a pixel color depending on its intensity.
First color is implicitly black (0, 0, 0).
Definition at line 88 of file dye.cpp.
◆ mColors
std::vector<Color> DyePalette::mColors |
|
private |
Definition at line 59 of file dye.h.
The documentation for this class was generated from the following files: