Public Methods |
| void | rgb2ihs (const real &r, const real &g, const real &b, real &i, real &h, real &s) |
| void | ihs2rgb (const real &i, const real &h, const real &s, real &r, real &g, real &b) |
| Color | ihs_interpolation (const real &value) |
| void | rgb2cie (const real &r, const real &g, const real &b, real &x, real &y, real &z) |
| void | cie2rgb (const real &l, const real &u, const real &v, real &x, real &y, real &z) |
| Color | cie_interpolation (const real &value) |
| void | rgb2luv (const real &r, const real &g, const real &b, real &l, real &u, real &v) |
| void | luv2rgb (const real &l, const real &u, const real &v, real &r, real &g, real &b) |
| Color | luv_interpolation (const real &value) |
| Color | getColor (const real &value, const char *colorspace="CIE") |
Public Attributes |
| Color | low |
| Color | high |
| real | min_value |
| real | max_value |
The "ColorScale" struct contains two floating point values (min_value, max_value) and two colors (low, high). The "low" color is associated with the minimum value, and the "high" color is associated with the maximum value. Functions for color conversion between RGB and the color spaces IHS, CIE and LUV are available. A floating point value between min_value and max_value can be given to find an associated color. The color is found using an interpolation in one of the above color spaces, based on the values of the data members of the struct, and the given floating point value.