22 #ifndef TETRAEDGE_TE_TE_COLOR_H 23 #define TETRAEDGE_TE_TE_COLOR_H 25 #include "common/types.h" 26 #include "common/stream.h" 35 TeColor(byte r, byte g, byte b, byte a);
37 byte &r() {
return _c[0]; };
38 byte &g() {
return _c[1]; };
39 byte &b() {
return _c[2]; };
40 byte &a() {
return _c[3]; };
42 const byte &r()
const {
return _c[0]; };
43 const byte &g()
const {
return _c[1]; };
44 const byte &b()
const {
return _c[2]; };
45 const byte &a()
const {
return _c[3]; };
47 uint32 getPacked()
const;
48 uint32 getPacked32()
const;
53 bool operator==(
const TeColor &c)
const {
54 return (_c[0] == c._c[0] && _c[1] == c._c[1] &&
55 _c[2] == c._c[2] && _c[3] == c._c[3]);
57 bool operator!=(
const TeColor &c) {
58 return !operator==(c);
63 _c[0], _c[1], _c[2], _c[3]);
76 #endif // TETRAEDGE_TE_TE_COLOR_H
Definition: detection.h:27
static String format(MSVC_PRINTF const char *fmt,...) GCC_PRINTF(1
Definition: te_color.h:30