#include <Color.hpp>
Public Member Functions | |
Color (const Color &color) | |
Color (GrayValue value) | |
Color (float_t value) | |
Color (unsigned char r, unsigned char g, unsigned char b) | |
operator float_t () const | |
Static Public Attributes | |
static const Color | BLUE |
static const Color | RED |
static const Color | CYAN |
static const Color | GREEN |
static const Color | YELLOW |
static const Color | MAGENTA |
static const Color | BLACK |
static const Color | WHITE |
Objects of this class represent 24-bit color pixel values, which are internally stored as a triple of integers ranging from 0 to 255.
imaging::Color::Color | ( | const Color & | color | ) | [inline] |
Copy constructor.
imaging::Color::Color | ( | GrayValue | value | ) | [inline] |
Initializes object from value. This function sets each channel to value.
imaging::Color::Color | ( | float_t | value | ) | [inline] |
Initializes object from value. This function sets each channel to 255 * value.
imaging::Color::Color | ( | unsigned char | r, | |
unsigned char | g, | |||
unsigned char | b | |||
) | [inline] |
Initializes object from red, green and blue values.
imaging::Color::operator float_t | ( | ) | const [inline] |
Type cast to float_t. The color value is converted to GrayValue and then divided by 255.
const Color imaging::Color::BLUE [static] |
Corresponds to the RGB values (0, 0, 255).
Referenced by imaging::operator<<().
const Color imaging::Color::RED [static] |
Corresponds to the RGB values (255, 0, 0).
Referenced by imaging::operator<<().
const Color imaging::Color::CYAN [static] |
Corresponds to the RGB values (0, 255, 255).
Referenced by imaging::operator<<().
const Color imaging::Color::GREEN [static] |
Corresponds to the RGB values (0, 255, 0).
const Color imaging::Color::YELLOW [static] |
Corresponds to the RGB values (255, 255, 0).
Referenced by imaging::operator<<().
const Color imaging::Color::MAGENTA [static] |
Corresponds to the RGB values (255, 0, 255).
const Color imaging::Color::BLACK [static] |
Corresponds to the RGB values (0, 0, 0).
const Color imaging::Color::WHITE [static] |
Corresponds to the RGB values (255, 255, 255).