34#include <NDEVR/Vector.h>
61 clip(x, 0.0f, 0.9505f)
73 m_values[
X] = (x > 0.9505f) ? 0.9505f : ((x < 0.0f) ? 0.0f : x);
77 m_values[
Y] = (y > 1.0000f) ? 1.0000f : ((y < 0.0f) ? 0.0f : y);
81 m_values[
Z] = (z > 1.0890f) ? 1.0890f : ((z < 0.0f) ? 0.0f : z);
89 static XYZColor D65(95.047f, 100.0f, 108.883f);
ACI colors are the standard colors used in AutoCAD-based products. Each color is identified by an ACI...
Definition ACIColor.h:58
The core Color class in the NDEVR API. Colors can be defined in several ways. The ACIColor is compact...
Definition Color.h:41
The HSB (Hue, Saturation, Brightness) color model defines a color space in terms of three constituent...
Definition HSBColor.h:57
The HSL (Hue, Saturation, Luminosity) color model defines a color space in.
Definition HSLColor.h:47
A Lab color space is a color-opponent space with dimension L for luminance and a and b for the color-...
Definition LABColor.h:61
Represents a color in the RGB space with optional alpha transparency.
Definition RGBColor.h:54
A fixed-size array with better performance compared to dynamic containers.
Definition Vector.hpp:60
fltp04 m_values[t_dims]
Definition Vector.hpp:623
In opposition to the previous models, the CIE XYZ model defines an absolute color space....
Definition XYZColor.h:51
NDEVR_BASE_API XYZColor(const HSBColor &)
constexpr XYZColor(fltp04 x, fltp04 y, fltp04 z, fltp04 a=1.0f)
Definition XYZColor.h:59
NDEVR_BASE_API XYZColor(const ACIColor &)
void setZ(fltp04 z)
Definition XYZColor.h:79
void setX(fltp04 x)
Definition XYZColor.h:71
NDEVR_BASE_API XYZColor(const RGBColor &)
constexpr XYZColor(const Vector< 4, fltp04 > &color)
Definition XYZColor.h:56
NDEVR_BASE_API XYZColor(const HSLColor &)
NDEVR_BASE_API XYZColor(const LABColor &)
void setA(fltp04 a)
Definition XYZColor.h:83
static XYZColor getD65()
Definition XYZColor.h:87
void setY(fltp04 y)
Definition XYZColor.h:75
constexpr XYZColor()
Definition XYZColor.h:53
constexpr t_type clip(const t_type &value, const t_type &lower_bound, const t_type &upper_bound)
Clips the value given so that that the returned value falls between upper and lower bound.
Definition BaseFunctions.hpp:207
float fltp04
Defines an alias representing a 4 byte floating-point number Bit layout is as follows: -Sign: 1 bit a...
Definition BaseValues.hpp:127
@ Y
Definition BaseValues.hpp:169
@ X
Definition BaseValues.hpp:167
@ Z
Definition BaseValues.hpp:171
@ W
Definition BaseValues.hpp:173
Defines for a given type (such as sint04, fltp08, UUID, etc) a maximum, minimum, and reserved 'invali...
Definition BaseValues.hpp:233