26 template <color_space ColorSpace,
typename BaseComponent,
typename ViewComponent,
typename Derived>
27 class basic_rgb_color;
33 hsv_color(
double aHue,
double aSaturation,
double aValue,
double aAlpha = 1.0);
34 template <color_space ColorSpace,
typename BaseComponent,
typename ViewComponent = BaseComponent,
typename Derived =
void>
57 template <
typename RgbColor>
58 typename RgbColor::return_type
to_rgb()
const
61 to_rgb(components.
x, components.
y, components.
z, components[3]);
62 typename RgbColor::return_type result;
63 result.set_red<
scalar>(components.
x);
64 result.set_green<
scalar>(components.
y);
65 result.set_blue<
scalar>(components.
z);
66 result.set_alpha<
scalar>(components[3]);
70 template <color_space ColorSpace,
typename BaseComponent,
typename ViewComponent = BaseComponent,
typename Derived =
void>
73 return from_rgb(aColor.template red<scalar>(), aColor.template green<scalar>(), aColor.template blue<scalar>(), aColor.template alpha<scalar>());
void set_alpha(double aAlpha)
RgbColor::return_type to_rgb() const
bool operator<(const hsv_color &aOther) const
static hsv_color from_rgb(const basic_rgb_color< ColorSpace, BaseComponent, ViewComponent, Derived > &aColor)
void set_hue(double aHue)
hsv_color brighter(double aCoeffecient, double aDelta) const
hsv_color with_hue(double aNewHue) const
static double undefined_hue()
double saturation() const
void to_rgb(scalar &aRed, scalar &aGreen, scalar &aBlue, scalar &aAlpha) const
hsv_color with_value(double aNewValue) const
hsv_color brighter(double aDelta) const
double brightness() const
hsv_color with_brightness(double aNewLightness) const
hsv_color with_saturation(double aNewSaturation) const
void set_brightness(double aBrightness)
bool operator==(const hsv_color &aOther) const
void set_value(double aValue)
bool operator!=(const hsv_color &aOther) const
hsv_color(double aHue, double aSaturation, double aValue, double aAlpha=1.0)
hsv_color(const basic_rgb_color< ColorSpace, BaseComponent, ViewComponent, Derived > &aColor)
bool hue_undefined() const
static hsv_color from_rgb(scalar aRed, scalar aGreen, scalar aBlue, scalar aAlpha=1.0)
void set_saturation(double aSaturation)