45 Color(uint32_t color);
48 Color(uint8_t r, uint8_t g, uint8_t b, uint8_t a = 255);
51 explicit Color(
const std::string& str);
83 uint32_t
ToInt()
const {
return color; }
uint8_t GetBlue() const
Get the blue component of the color.
Definition: TmxColor.cpp:85
uint8_t GetGreen() const
Get the green component of the color.
Definition: TmxColor.cpp:80
bool operator==(const Color &o)
Check if two colors have the exact same four components.
Definition: TmxColor.h:62
bool operator!=(const Color &o)
Check if two colors are different.
Definition: TmxColor.h:65
Color & operator=(const Color &)=default
Default asignment operator.
uint8_t GetAlpha() const
Get the alpha component of the color.
Definition: TmxColor.cpp:70
uint32_t ToInt() const
Get the 32 bits integer representing the color. The 8 highest bits are for the alpha channel...
Definition: TmxColor.h:83
uint8_t GetRed() const
Get the red component of the color.
Definition: TmxColor.cpp:75
std::string ToString() const
Get a string representation of the color in the format "#AARRGGBB".
Definition: TmxColor.cpp:95
Color()
Default constructor for a fully transparent black color.
Definition: TmxColor.cpp:34
A class used for storing information about a color.
Definition: TmxColor.h:38
bool IsTransparent() const
Return true if the color is fully transparent (ie alpha value is 0).
Definition: TmxColor.cpp:90