diff options
author | chai <chaifix@163.com> | 2018-05-16 15:02:43 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2018-05-16 15:02:43 +0800 |
commit | fdaf0e7eb6b9d9bdd7d5ab5f814f4ebbf791ff67 (patch) | |
tree | 6b9712381d6bce07554491acf900ec4b27e6ecb0 /src/render/color.h |
v0.1.0
Diffstat (limited to 'src/render/color.h')
-rw-r--r-- | src/render/color.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/render/color.h b/src/render/color.h new file mode 100644 index 0000000..dfb02e1 --- /dev/null +++ b/src/render/color.h @@ -0,0 +1,27 @@ +/** +* Some color operating here. +*/ +#ifndef __JIN_COLOR_H +#define __JIN_COLOR_H +#include "utils/endian.h" + +namespace jin +{ +namespace render +{ + + union color { + struct { +#if JIN_BYTEORDER == JIN_BIG_ENDIAN + unsigned char r, g, b, a; +#else + unsigned char a, b, g, r; +#endif + }rgba; + int word; + }; + +} +} + +#endif |