Skip to content
Snippets Groups Projects
Commit b3727a18 authored by Rainer Kartmann's avatar Rainer Kartmann
Browse files

Add KIT colors

parent 23ea8f7f
No related branches found
No related tags found
No related merge requests found
......@@ -66,97 +66,54 @@ namespace simox::color
// Colorless
static inline Color black(int a = 255)
{
return Color(0, 0, 0, a);
}
static inline Color white(int a = 255)
{
return Color(255, 255, 255, a);
}
static inline Color gray(int g = 128, int a = 255)
{
return Color(g, g, g, a);
}
static inline Color black(int a = 255) { return Color(0, 0, 0, a); }
static inline Color white(int a = 255) { return Color(255, 255, 255, a); }
static inline Color gray(int g = 128, int a = 255) { return Color(g, g, g, a); }
// Primary colors
static inline Color red(int r = 255, int a = 255)
{
return Color(r, 0, 0, a);
}
static inline Color green(int g = 255, int a = 255)
{
return Color(0, g, 0, a);
}
static inline Color blue(int b = 255, int a = 255)
{
return Color(0, 0, b, a);
}
static inline Color red(int r = 255, int a = 255) { return Color(r, 0, 0, a); }
static inline Color green(int g = 255, int a = 255) { return Color(0, g, 0, a); }
static inline Color blue(int b = 255, int a = 255) { return Color(0, 0, b, a); }
// Secondary colors
/// Green + Blue
static inline Color cyan(int c = 255, int a = 255)
{
return Color(0, c, c, a);
}
static inline Color cyan(int c = 255, int a = 255) { return Color(0, c, c, a); }
/// Red + Green
static inline Color yellow(int y = 255, int a = 255)
{
return Color(y, y, 0, a);
}
static inline Color yellow(int y = 255, int a = 255) { return Color(y, y, 0, a); }
/// Red + Blue
static inline Color magenta(int m = 255, int a = 255)
{
return Color(m, 0, m, a);
}
static inline Color magenta(int m = 255, int a = 255) { return Color(m, 0, m, a); }
// 2:1 Mixed colors
/// 2 Red + 1 Green
static inline Color orange(int o = 255, int a = 255)
{
return Color(o, o / 2, 0, a);
}
static inline Color orange(int o = 255, int a = 255) { return Color(o, o / 2, 0, a); }
/// 2 Red + 1 Blue
static inline Color pink(int p = 255, int a = 255)
{
return Color(p, p / 2, 0, a);
}
static inline Color pink(int p = 255, int a = 255) { return Color(p, p / 2, 0, a); }
/// 2 Green + 1 Red
static inline Color lime(int l = 255, int a = 255)
{
return Color(l / 2, l, 0, a);
}
static inline Color lime(int l = 255, int a = 255) { return Color(l / 2, l, 0, a); }
/// 2 Green + 1 Blue
static inline Color turquoise(int t = 255, int a = 255)
{
return Color(0, t, t / 2, a);
}
static inline Color turquoise(int t = 255, int a = 255) { return Color(0, t, t / 2, a); }
/// 2 Blue + 1 Green
static inline Color azure(int az = 255, int a = 255)
{
return Color(0, az / 2, az, a);
}
static inline Color azure(int az = 255, int a = 255) { return Color(0, az / 2, az, a); }
/// 2 Blue + 1 Red
static inline Color purple(int p = 255, int a = 255)
{
return Color(0, p / 2, p, a);
}
static inline Color purple(int p = 255, int a = 255) { return Color(0, p / 2, p, a); }
// KIT colors (source: https://www.sek.kit.edu/downloads/2_Gestaltungsgrundlagen_Farben.pdf)
static inline Color kit_green(int a = 255) { return Color( 0, 150, 130, a); }
static inline Color kit_blue(int a = 255) { return Color(140, 182, 60, a); }
static inline Color kit_maygreen(int a = 255) { return Color(140, 182, 60, a); }
static inline Color kit_yellow(int a = 255) { return Color(252, 229, 0, a); }
static inline Color kit_orange(int a = 255) { return Color(223, 155, 27, a); }
static inline Color kit_brown(int a = 255) { return Color(167, 130, 46, a); }
static inline Color kit_red(int a = 255) { return Color(162, 34, 35, a); }
static inline Color kit_purple(int a = 255) { return Color(163, 16, 124, a); }
static inline Color kit_cyan(int a = 255) { return Color( 35, 161, 224, a); }
};
......
......@@ -6,6 +6,9 @@
namespace simox::color::cmaps
{
// Source: https://matplotlib.org/3.1.0/tutorials/colors/colormaps.html
// Perceptually Uniform Sequential
ColorMap viridis();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment