4
uint8_t buf[COUNT * 4];
5
uint8_t rgb[COUNT * 4];
11
int stream_ptr, pixel_ptr;
17
unsigned char a, r, g, b;
20
a = buf[stream_ptr++];
21
r = buf[stream_ptr++];
22
g = buf[stream_ptr++];
23
b = buf[stream_ptr++];
24
argb = (a << 24) | (r << 16) | (g << 8) | (b << 0);
25
*(unsigned int *)(&rgb[pixel_ptr]) = argb;