Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: ColorLib.h
- Revision:
- 6:5aff0da4b663
- Parent:
- 3:786b31c65e7a
- Child:
- 10:db7308876f3e
diff -r 8e6835a94e10 -r 5aff0da4b663 ColorLib.h
--- a/ColorLib.h Fri Jul 29 04:22:53 2016 +0000
+++ b/ColorLib.h Mon Aug 01 08:16:52 2016 +0000
@@ -36,6 +36,46 @@
#define GetBValue(rgb) ((uint8_t)((rgb) >> 16))
#define COLORREF(r, g ,b) ((uint32_t)((uint8_t)(r) | ((uint8_t)(g) << 8) | ((uint8_t)(b) << 16)))
+enum SystemColor
+{
+ CL_BLACK = COLORREF(0x00, 0x00, 0x00),
+ CL_RED = COLORREF(0xFF, 0x00, 0x00),
+ CL_LIME = COLORREF(0x00, 0xFF, 0x00),
+ CL_YELLOW = COLORREF(0xFF, 0xFF, 0x00),
+ CL_BLUE = COLORREF(0x00, 0x00, 0xFF),
+ CL_FUCHSIA = COLORREF(0xFF, 0x00, 0xFF),
+ CL_MAGENTA = COLORREF(0xFF, 0x00, 0xFF),
+ CL_AQUA = COLORREF(0x00, 0xFF, 0xFF),
+ CL_CYAN = COLORREF(0x00, 0xFF, 0xFF),
+ CL_WHITE = COLORREF(0xFF, 0xFF, 0xFF),
+
+ CL_MAROON = COLORREF(0x80, 0x00, 0x00),
+ CL_GREEN = COLORREF(0x00, 0x80, 0x00),
+ CL_OLIVE = COLORREF(0x80, 0x80, 0x00),
+ CL_NAVY = COLORREF(0x00, 0x00, 0x80),
+ CL_PURPLE = COLORREF(0x80, 0x00, 0x80),
+ CL_TEAL = COLORREF(0x00, 0x80, 0x80),
+ CL_GRAY = COLORREF(0x80, 0x80, 0x80),
+
+ CL_GOLD = COLORREF(0xFF, 0xD7, 0x00),
+ CL_SILVER = COLORREF(0xC0, 0xC0, 0xC0),
+
+ CL_IVORY = COLORREF(0xFF, 0xFF, 0xF0),
+ CL_LIGHTBLUE = COLORREF(0xAD, 0xD8, 0xE6),
+ CL_LIGHTCYAN = COLORREF(0xE0, 0xFF, 0xFF),
+ CL_LIGHTGREEN = COLORREF(0x90, 0xEE, 0x90),
+ CL_LIGHTGRAY = COLORREF(0xD3, 0xD3, 0xD3),
+ CL_LIGHTPINK = COLORREF(0xFF, 0xB6, 0xC1),
+ CL_LIGHTYELLOW = COLORREF(0xFF, 0xFF, 0xE0),
+ CL_PINK = COLORREF(0xFF, 0xC0, 0xCB),
+ CL_SKYBLUE = COLORREF(0x87, 0xCE, 0xEB),
+ CL_VIOLET = COLORREF(0xEE, 0x82, 0xEE),
+ CL_YELLOWGREEN = COLORREF(0x9A, 0xCD, 0x32),
+ CL_GREENYELLOW = COLORREF(0xAD, 0xFF, 0x2F),
+ CL_CANDLE = COLORREF(255, 147, 41), /* 1900 K */
+};
+
+//----------------------------------------------------------------------------
struct RGBColor;
struct HSVColor;
@@ -255,4 +295,9 @@
};
//----------------------------------------------------------------------------
+extern const uint8_t gamma20_table[256];
+
+RGBColor GammaColor(RGBColor color);
+
+//----------------------------------------------------------------------------
#endif // end of COLORLIB_H