2694
|
1 /*
|
2504
|
2 *
|
2506
|
3 * rgb2rgb.h, Software RGB to RGB convertor
|
2732
|
4 * pluralize by Software PAL8 to RGB convertor
|
|
5 * Software YUV to YUV convertor
|
|
6 * Software YUV to RGB convertor
|
2504
|
7 */
|
|
8
|
|
9 #ifndef RGB2RGB_INCLUDED
|
|
10 #define RGB2RGB_INCLUDED
|
|
11
|
2718
|
12 extern void rgb24to32(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
6492
|
13 extern void rgb24to16(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
|
14 extern void rgb24to15(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
2718
|
15 extern void rgb32to24(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
2721
|
16 extern void rgb32to16(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
|
17 extern void rgb32to15(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
6492
|
18 extern void rgb15to16(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
|
19 extern void rgb15to24(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
|
20 extern void rgb15to32(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
|
21 extern void rgb16to24(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
|
22 extern void rgb16to32(const uint8_t *src,uint8_t *dst,unsigned src_size);
|
2758
|
23 extern void rgb32tobgr32(const uint8_t *src, uint8_t *dst, unsigned src_size);
|
5582
|
24 extern void rgb24tobgr24(const uint8_t *src, uint8_t *dst, unsigned src_size);
|
2504
|
25
|
2694
|
26
|
2718
|
27 extern void palette8torgb32(const uint8_t *src, uint8_t *dst, unsigned num_pixels, const uint8_t *palette);
|
|
28 extern void palette8torgb16(const uint8_t *src, uint8_t *dst, unsigned num_pixels, const uint8_t *palette);
|
|
29 extern void palette8torgb15(const uint8_t *src, uint8_t *dst, unsigned num_pixels, const uint8_t *palette);
|
|
30 extern void palette8torgb24(const uint8_t *src, uint8_t *dst, unsigned num_pixels, const uint8_t *palette);
|
|
31
|
2723
|
32 extern void yv12toyuy2(const uint8_t *ysrc, const uint8_t *usrc, const uint8_t *vsrc, uint8_t *dst,
|
2725
|
33 unsigned int width, unsigned int height,
|
|
34 unsigned int lumStride, unsigned int chromStride, unsigned int dstStride);
|
5588
|
35 extern void yuv422ptoyuy2(const uint8_t *ysrc, const uint8_t *usrc, const uint8_t *vsrc, uint8_t *dst,
|
|
36 unsigned int width, unsigned int height,
|
|
37 unsigned int lumStride, unsigned int chromStride, unsigned int dstStride);
|
2724
|
38 extern void yuy2toyv12(const uint8_t *src, uint8_t *ydst, uint8_t *udst, uint8_t *vdst,
|
2725
|
39 unsigned int width, unsigned int height,
|
|
40 unsigned int lumStride, unsigned int chromStride, unsigned int srcStride);
|
3633
|
41 extern void rgb24toyv12(const uint8_t *src, uint8_t *ydst, uint8_t *udst, uint8_t *vdst,
|
|
42 unsigned int width, unsigned int height,
|
|
43 unsigned int lumStride, unsigned int chromStride, unsigned int srcStride);
|
2701
|
44
|
5337
|
45 extern void interleaveBytes(uint8_t *src1, uint8_t *src2, uint8_t *dst,
|
6492
|
46 unsigned width, unsigned height, unsigned src1Stride,
|
|
47 unsigned src2Stride, unsigned dstStride);
|
5337
|
48
|
|
49
|
2732
|
50 #define MODE_RGB 0x1
|
|
51 #define MODE_BGR 0x2
|
|
52
|
|
53 typedef void (* yuv2rgb_fun) (uint8_t * image, uint8_t * py,
|
|
54 uint8_t * pu, uint8_t * pv,
|
6492
|
55 unsigned h_size, unsigned v_size,
|
|
56 unsigned rgb_stride, unsigned y_stride, unsigned uv_stride);
|
2732
|
57
|
|
58 extern yuv2rgb_fun yuv2rgb;
|
|
59
|
6492
|
60 void yuv2rgb_init (unsigned bpp, int mode);
|
2732
|
61
|
2504
|
62 #endif
|