gwnavruntime/visualsystem/color.h Source File
Go to the documentation of this file.
25 Color(
KyUInt32 rgba) { Set(rgba >> 24, (rgba >> 16) & 0xFF, (rgba >> 8) & 0xFF, rgba & 0xFF); }
33 bool operator==(
const Color& c)
const {
return r == c.
r &&
g == c.
g &&
b == c.
b &&
a == c.
a; }
34 bool operator!=(
const Color& c)
const {
return !operator==(c); }
62 static const KyUInt32 White = 0xFFFFFFFF;
63 static const KyUInt32 LightGrey = 0xD3D3D3FF;
64 static const KyUInt32 Grey = 0x808080FF;
65 static const KyUInt32 DimGrey = 0x696969FF;
66 static const KyUInt32 Black = 0x000000FF;
69 static const KyUInt32 Red = 0xFF0000FF;
70 static const KyUInt32 Green = 0x00FF00FF;
71 static const KyUInt32 Blue = 0x0000FFFF;
72 static const KyUInt32 Magenta = 0xFF00FFFF;
73 static const KyUInt32 Cyan = 0x00FFFFFF;
74 static const KyUInt32 Yellow = 0xFFFF00FF;
75 static const KyUInt32 Orange = 0xFFA500FF;
78 static const KyUInt32 Khaki = 0xF0E68CFF;
79 static const KyUInt32 Tan = 0xD2B48CFF;
80 static const KyUInt32 Chocolate = 0xD2691EFF;
81 static const KyUInt32 Salmon = 0xFA8072FF;
82 static const KyUInt32 OrangeRed = 0xFF4500FF;
83 static const KyUInt32 Brown = 0xA52A2AFF;
86 static const KyUInt32 GreenYellow = 0xADFF2FFF;
87 static const KyUInt32 LightGreen = 0x90EE90FF;
88 static const KyUInt32 LightSeaGreen = 0x20B2AAFF;
89 static const KyUInt32 DarkSeaGreen = 0x8FBC8FFF;
90 static const KyUInt32 Teal = 0x008080FF;
93 static const KyUInt32 SkyBlue = 0x87CEEBFF;
94 static const KyUInt32 DeepSkyBlue = 0x00BFFFFF;
95 static const KyUInt32 RoyalBlue = 0x4169E1FF;
96 static const KyUInt32 MediumBlue = 0x0000CDFF;
99 static const KyUInt32 Violet = 0xEE82EEFF;
100 static const KyUInt32 HotPink = 0xFF69B4FF;
101 static const KyUInt32 MediumPurple = 0x9370DBFF;
102 static const KyUInt32 Purple = 0x800080FF;
105 static const KyUInt32 TransparentBlack = 0xFFFFFF00;
106 static const KyUInt32 Invisible = 0xFFFFFF00;
Color(KyUInt32 rgba)
w parameters in [0, 255] a=0 is fully transparent, a=255 is opaque
Definition: color.h:25
KyUInt8 a
alpha
Definition: color.h:49
KyUInt8 b
blue
Definition: color.h:48
KyUInt8 g
green
Definition: color.h:47
std::uint32_t KyUInt32
uint32_t
Definition: types.h:29
KyUInt8 r
red
Definition: color.h:46
Color()
opaque black
Definition: color.h:21
void SetFloat(KyFloat32 r_, KyFloat32 g_, KyFloat32 b_, KyFloat32 a_=1.0f)
parameters in [0.0f, 1.0f], a=0.0f is fully transparent, a=1.0f is fully opaque
Definition: color.h:40
#define KY_DEFINE_NEW_DELETE_OPERATORS(MemStat)
This macro defines new and delete operators.
Definition: memory.h:132
Target
Enumerates the possible endianness types relative to the current platform.
Definition: endianness.h:27
bool IsOpaque() const
alpha == 255
Definition: color.h:30
#define KY_DEPRECATED(expr)
The compiler issues a warning when a deprecated function or typedef is used.
Definition: types.h:93
The Autodesk Navigation namespace.
Definition: gamekitcrowddispersion.cpp:17
RGBA color.
Definition: color.h:16
bool IsTransparent() const
alpha != 255
Definition: color.h:31
bool IsVisible() const
alpha != 0
Definition: color.h:29
static Color GetDistinctColor(KyUInt32 index)
Retrieves the color with the specified index within a limited internal palette of 31 distinct colors...
Definition: color.cpp:40
std::uint8_t KyUInt8
uint8_t
Definition: types.h:27
float KyFloat32
float
Definition: types.h:32