Class for working with an RGBA-color.
Подробнее...
|
typedef unsigned int | value_t |
|
|
| Color (value_t r, value_t g, value_t b, value_t a=0xFF) |
| Constructor for building a color by RGBA-channels. Подробнее...
|
|
Class for working with an RGBA-color.
- Начиная с
- 4.5.32odo fine? Include the
comms::cColor
.
coat::scripto::Color::Color |
( |
value_t |
r, |
|
|
value_t |
g, |
|
|
value_t |
b, |
|
|
value_t |
a = 0xFF |
|
) |
| |
|
inline |
Constructor for building a color by RGBA-channels.
Color a( 0x22, 0x8b, 0x22, 202 );
const Color coat::scripto::Color::WHITE |
|
static |
Инициализатор{}
bool operator==( const Color& b ) const { return a.value == b.a.value; }
bool operator!=( const Color& b ) const { return a.value != b.a.value; }
Color& value( const value_t& v ) { a.value = v; return *this; }
value_t value() const { return a.value; }
value_t red() const { return value() & 0xFF; }
value_t green() const { return (value() >> 8) & 0xFF; }
value_t blue() const { return (value() >> 16) & 0xFF; }
value_t alpha() const { return (value() >> 24) & 0xFF; }
static const Color EMPTY