blob: dc6789e892b1c5398b8e7dc2e0c0b06cc5e1c3d0 (
plain)
| 1
2
3
4
5
6
7
8
9
10
11
 | #define uint        unsigned int
#define uint8       unsigned char
#define uint16      uint16_t
#define uint32      unsigned int
#define COLTOINT(R,G,B)     (((unsigned int)R)<<16)|(((unsigned int)G)<<8)|(unsigned int)B
#define INTTOCOL(C)         (C>>16), ((C>>8)%256), (C%256)
#define COLTOINTA(R,G,B,A)  (((COLTOINT(R,G,B)) << 8)|(unsigned int)A)
#define INTTOCOLA(C)        (C>>24), ((C>>16)&0xFF), ((C>>8)&0xFF), (C&0xFF)
#define LENGTH(S)           ((sizeof S)/(sizeof S[0]))
 |