50 #define CLIP(color) (unsigned char)(((color)>0xFF)?0xff:(((color)<0)?0:(color))) 53 RGB24_TO_Y(
unsigned char r,
unsigned char g,
unsigned char b);
56 YR_TO_V(
unsigned char r,
unsigned char y);
59 YB_TO_U(
unsigned char b,
unsigned char y);
62 R_FROMYV(
unsigned char y,
unsigned char v);
65 G_FROMYUV(
unsigned char y,
unsigned char u,
unsigned char v);
68 B_FROMYU(
unsigned char y,
unsigned char u);
70 #define YfromRGB(r,g,b) CLIP((77*(r)+150*(g)+29*(b))>>8) 71 #define UfromRGB(r,g,b) CLIP(((128*(b)-85*(g)-43*(r))>>8 )+128) 72 #define VfromRGB(r,g,b) CLIP(((128*(r)-107*(g)-21*(b))>>8) +128) 74 #define PACKRGB16(r,g,b) (__u16) ((((b) & 0xF8) << 8 ) | (((g) & 0xFC) << 3 ) | (((r) & 0xF8) >> 3 )) 75 #define UNPACK16(pixel,r,g,b) r=((pixel)&0xf800) >> 8; g=((pixel)&0x07e0) >> 3; b=(((pixel)&0x001f) << 3)
unsigned char B_FROMYU(unsigned char y, unsigned char u)
unsigned char G_FROMYUV(unsigned char y, unsigned char u, unsigned char v)
unsigned char YR_TO_V(unsigned char r, unsigned char y)
unsigned char RGB24_TO_Y(unsigned char r, unsigned char g, unsigned char b)
unsigned char R_FROMYV(unsigned char y, unsigned char v)
unsigned char YB_TO_U(unsigned char b, unsigned char y)