Added named colors

This commit is contained in:
Jaby
2022-09-11 10:17:02 +02:00
parent 3317867f1d
commit db3196b290
2 changed files with 23 additions and 1 deletions

View File

@@ -15,6 +15,26 @@ namespace GPU {
constexpr uint32_t raw() const {
return ((this->blue << 16) | (this->green << 8) | this->red);
}
static constexpr Color Black() {
return Color(0, 0, 0);
}
static constexpr Color White() {
return Color(0xFF, 0xFF, 0xFF);
}
static constexpr Color Red() {
return Color(0xFF, 0x0, 0x0);
}
static constexpr Color Green() {
return Color(0x0, 0x0, 0xFF);
}
static constexpr Color Blue() {
return Color(0x0, 0x0, 0xFF);
}
};
template<typename T>