RGB2YUV_SHIFT 54 libswscale/input.c dst[i] = (ry*r + gy*g + by*b + (0x2001<<(RGB2YUV_SHIFT-1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 72 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (0x10001<<(RGB2YUV_SHIFT-1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 73 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (0x10001<<(RGB2YUV_SHIFT-1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 91 libswscale/input.c dstU[i]= (ru*r + gu*g + bu*b + (0x10001<<(RGB2YUV_SHIFT-1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 92 libswscale/input.c dstV[i]= (rv*r + gv*g + bv*b + (0x10001<<(RGB2YUV_SHIFT-1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 142 libswscale/input.c dst[i] = (ry*r + gy*g + by*b + (0x2001 << (RGB2YUV_SHIFT - 1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 163 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (0x10001 << (RGB2YUV_SHIFT - 1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 164 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (0x10001 << (RGB2YUV_SHIFT - 1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 188 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (0x10001 << (RGB2YUV_SHIFT - 1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 189 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (0x10001 << (RGB2YUV_SHIFT - 1))) >> RGB2YUV_SHIFT; RGB2YUV_SHIFT 378 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_BGR32, bgr32, 16, 0, 0, 0, 0xFF0000, 0xFF00, 0x00FF, 8, 0, 8, RGB2YUV_SHIFT + 8) RGB2YUV_SHIFT 379 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_BGR32_1, bgr321, 16, 0, 0, 8, 0xFF0000, 0xFF00, 0x00FF, 8, 0, 8, RGB2YUV_SHIFT + 8) RGB2YUV_SHIFT 380 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_RGB32, rgb32, 0, 0, 16, 0, 0x00FF, 0xFF00, 0xFF0000, 8, 0, 8, RGB2YUV_SHIFT + 8) RGB2YUV_SHIFT 381 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_RGB32_1, rgb321, 0, 0, 16, 8, 0x00FF, 0xFF00, 0xFF0000, 8, 0, 8, RGB2YUV_SHIFT + 8) RGB2YUV_SHIFT 382 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_BGR565LE, bgr16le, 0, 0, 0, 0, 0x001F, 0x07E0, 0xF800, 11, 5, 0, RGB2YUV_SHIFT + 8) RGB2YUV_SHIFT 383 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_BGR555LE, bgr15le, 0, 0, 0, 0, 0x001F, 0x03E0, 0x7C00, 10, 5, 0, RGB2YUV_SHIFT + 7) RGB2YUV_SHIFT 384 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_BGR444LE, bgr12le, 0, 0, 0, 0, 0x000F, 0x00F0, 0x0F00, 8, 4, 0, RGB2YUV_SHIFT + 4) RGB2YUV_SHIFT 385 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_RGB565LE, rgb16le, 0, 0, 0, 0, 0xF800, 0x07E0, 0x001F, 0, 5, 11, RGB2YUV_SHIFT + 8) RGB2YUV_SHIFT 386 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_RGB555LE, rgb15le, 0, 0, 0, 0, 0x7C00, 0x03E0, 0x001F, 0, 5, 10, RGB2YUV_SHIFT + 7) RGB2YUV_SHIFT 387 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_RGB444LE, rgb12le, 0, 0, 0, 0, 0x0F00, 0x00F0, 0x000F, 0, 4, 8, RGB2YUV_SHIFT + 4) RGB2YUV_SHIFT 388 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_BGR565BE, bgr16be, 0, 0, 0, 0, 0x001F, 0x07E0, 0xF800, 11, 5, 0, RGB2YUV_SHIFT + 8) RGB2YUV_SHIFT 389 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_BGR555BE, bgr15be, 0, 0, 0, 0, 0x001F, 0x03E0, 0x7C00, 10, 5, 0, RGB2YUV_SHIFT + 7) RGB2YUV_SHIFT 390 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_BGR444BE, bgr12be, 0, 0, 0, 0, 0x000F, 0x00F0, 0x0F00, 8, 4, 0, RGB2YUV_SHIFT + 4) RGB2YUV_SHIFT 391 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_RGB565BE, rgb16be, 0, 0, 0, 0, 0xF800, 0x07E0, 0x001F, 0, 5, 11, RGB2YUV_SHIFT + 8) RGB2YUV_SHIFT 392 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_RGB555BE, rgb15be, 0, 0, 0, 0, 0x7C00, 0x03E0, 0x001F, 0, 5, 10, RGB2YUV_SHIFT + 7) RGB2YUV_SHIFT 393 libswscale/input.c rgb16_32_wrapper(AV_PIX_FMT_RGB444BE, rgb12be, 0, 0, 0, 0, 0x0F00, 0x00F0, 0x000F, 0, 4, 8, RGB2YUV_SHIFT + 4) RGB2YUV_SHIFT 410 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (0x4001<<(RGB2YUV_SHIFT-6))) >> (RGB2YUV_SHIFT-6+1); RGB2YUV_SHIFT 411 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (0x4001<<(RGB2YUV_SHIFT-6))) >> (RGB2YUV_SHIFT-6+1); RGB2YUV_SHIFT 775 libswscale/input.c dst[i] = ((ry*r + gy*g + by*b + (32<<(RGB2YUV_SHIFT-1)) + (1<<(RGB2YUV_SHIFT-7)))>>(RGB2YUV_SHIFT-6)); RGB2YUV_SHIFT 792 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (256<<(RGB2YUV_SHIFT-1)) + (1<<(RGB2YUV_SHIFT-7)))>>(RGB2YUV_SHIFT-6); RGB2YUV_SHIFT 793 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (256<<(RGB2YUV_SHIFT-1)) + (1<<(RGB2YUV_SHIFT-7)))>>(RGB2YUV_SHIFT-6); RGB2YUV_SHIFT 811 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (256<<RGB2YUV_SHIFT) + (1<<(RGB2YUV_SHIFT-6)))>>(RGB2YUV_SHIFT-5); RGB2YUV_SHIFT 812 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (256<<RGB2YUV_SHIFT) + (1<<(RGB2YUV_SHIFT-6)))>>(RGB2YUV_SHIFT-5); RGB2YUV_SHIFT 828 libswscale/input.c dst[i] = ((ry*r + gy*g + by*b + (32<<(RGB2YUV_SHIFT-1)) + (1<<(RGB2YUV_SHIFT-7)))>>(RGB2YUV_SHIFT-6)); RGB2YUV_SHIFT 846 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (256<<(RGB2YUV_SHIFT-1)) + (1<<(RGB2YUV_SHIFT-7)))>>(RGB2YUV_SHIFT-6); RGB2YUV_SHIFT 847 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (256<<(RGB2YUV_SHIFT-1)) + (1<<(RGB2YUV_SHIFT-7)))>>(RGB2YUV_SHIFT-6); RGB2YUV_SHIFT 865 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (256<<RGB2YUV_SHIFT) + (1<<(RGB2YUV_SHIFT-6)))>>(RGB2YUV_SHIFT-5); RGB2YUV_SHIFT 866 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (256<<RGB2YUV_SHIFT) + (1<<(RGB2YUV_SHIFT-6)))>>(RGB2YUV_SHIFT-5); RGB2YUV_SHIFT 880 libswscale/input.c dst[i] = (ry*r + gy*g + by*b + (0x801<<(RGB2YUV_SHIFT-7))) >> (RGB2YUV_SHIFT-6); RGB2YUV_SHIFT 904 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (0x4001<<(RGB2YUV_SHIFT-7))) >> (RGB2YUV_SHIFT-6); RGB2YUV_SHIFT 905 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (0x4001<<(RGB2YUV_SHIFT-7))) >> (RGB2YUV_SHIFT-6); RGB2YUV_SHIFT 924 libswscale/input.c dst[i] = ((ry*r + gy*g + by*b + (33 << (RGB2YUV_SHIFT + bpc - 9))) >> (RGB2YUV_SHIFT + shift - 14)); RGB2YUV_SHIFT 957 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (257 << (RGB2YUV_SHIFT + bpc - 9))) >> (RGB2YUV_SHIFT + shift - 14); RGB2YUV_SHIFT 958 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (257 << (RGB2YUV_SHIFT + bpc - 9))) >> (RGB2YUV_SHIFT + shift - 14); RGB2YUV_SHIFT 991 libswscale/input.c dstU[i] = (ru*r + gu*g + bu*b + (257 << (RGB2YUV_SHIFT + bpc - 9))) >> (RGB2YUV_SHIFT + shift - 14); RGB2YUV_SHIFT 992 libswscale/input.c dstV[i] = (rv*r + gv*g + bv*b + (257 << (RGB2YUV_SHIFT + bpc - 9))) >> (RGB2YUV_SHIFT + shift - 14); RGB2YUV_SHIFT 1010 libswscale/input.c dst[i] = ((ry*r + gy*g + by*b + (33 << (RGB2YUV_SHIFT + bpc - 9))) >> (RGB2YUV_SHIFT + shift - 14)); RGB2YUV_SHIFT 117 libswscale/rgb2rgb.c #define BY ((int)( 0.098 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 118 libswscale/rgb2rgb.c #define BV ((int)(-0.071 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 119 libswscale/rgb2rgb.c #define BU ((int)( 0.439 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 120 libswscale/rgb2rgb.c #define GY ((int)( 0.504 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 121 libswscale/rgb2rgb.c #define GV ((int)(-0.368 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 122 libswscale/rgb2rgb.c #define GU ((int)(-0.291 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 123 libswscale/rgb2rgb.c #define RY ((int)( 0.257 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 124 libswscale/rgb2rgb.c #define RV ((int)( 0.439 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 125 libswscale/rgb2rgb.c #define RU ((int)(-0.148 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 668 libswscale/rgb2rgb_template.c unsigned int Y = ((ry * r + gy * g + by * b) >> RGB2YUV_SHIFT) + 16; RGB2YUV_SHIFT 669 libswscale/rgb2rgb_template.c unsigned int V = ((rv * r + gv * g + bv * b) >> RGB2YUV_SHIFT) + 128; RGB2YUV_SHIFT 670 libswscale/rgb2rgb_template.c unsigned int U = ((ru * r + gu * g + bu * b) >> RGB2YUV_SHIFT) + 128; RGB2YUV_SHIFT 680 libswscale/rgb2rgb_template.c Y = ((ry * r + gy * g + by * b) >> RGB2YUV_SHIFT) + 16; RGB2YUV_SHIFT 694 libswscale/rgb2rgb_template.c unsigned int Y = ((ry * r + gy * g + by * b) >> RGB2YUV_SHIFT) + 16; RGB2YUV_SHIFT 702 libswscale/rgb2rgb_template.c Y = ((ry * r + gy * g + by * b) >> RGB2YUV_SHIFT) + 16; RGB2YUV_SHIFT 867 libswscale/swscale.c #define BY ( (int) (0.114 * 219 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 868 libswscale/swscale.c #define BV (-(int) (0.081 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 869 libswscale/swscale.c #define BU ( (int) (0.500 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 870 libswscale/swscale.c #define GY ( (int) (0.587 * 219 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 871 libswscale/swscale.c #define GV (-(int) (0.419 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 872 libswscale/swscale.c #define GU (-(int) (0.331 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 873 libswscale/swscale.c #define RY ( (int) (0.299 * 219 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 874 libswscale/swscale.c #define RV ( (int) (0.500 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 875 libswscale/swscale.c #define RU (-(int) (0.169 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)) RGB2YUV_SHIFT 877 libswscale/swscale.c y = av_clip_uint8((RY * r + GY * g + BY * b + ( 33 << (RGB2YUV_SHIFT - 1))) >> RGB2YUV_SHIFT); RGB2YUV_SHIFT 878 libswscale/swscale.c u = av_clip_uint8((RU * r + GU * g + BU * b + (257 << (RGB2YUV_SHIFT - 1))) >> RGB2YUV_SHIFT); RGB2YUV_SHIFT 879 libswscale/swscale.c v = av_clip_uint8((RV * r + GV * g + BV * b + (257 << (RGB2YUV_SHIFT - 1))) >> RGB2YUV_SHIFT); RGB2YUV_SHIFT 413 libswscale/swscale_internal.h #define RGB2YUV_SHIFT 15 RGB2YUV_SHIFT 800 libswscale/utils.c c->input_rgb2yuv_table[RY_IDX] = -ROUNDED_DIV((1 << RGB2YUV_SHIFT)*V , Cy); RGB2YUV_SHIFT 801 libswscale/utils.c c->input_rgb2yuv_table[GY_IDX] = ROUNDED_DIV((1 << RGB2YUV_SHIFT)*ONE*ONE , Cy); RGB2YUV_SHIFT 802 libswscale/utils.c c->input_rgb2yuv_table[BY_IDX] = -ROUNDED_DIV((1 << RGB2YUV_SHIFT)*W , Cy); RGB2YUV_SHIFT 804 libswscale/utils.c c->input_rgb2yuv_table[RU_IDX] = ROUNDED_DIV((1 << RGB2YUV_SHIFT)*V , Cu); RGB2YUV_SHIFT 805 libswscale/utils.c c->input_rgb2yuv_table[GU_IDX] = -ROUNDED_DIV((1 << RGB2YUV_SHIFT)*ONE*ONE , Cu); RGB2YUV_SHIFT 806 libswscale/utils.c c->input_rgb2yuv_table[BU_IDX] = ROUNDED_DIV((1 << RGB2YUV_SHIFT)*(Z+W) , Cu); RGB2YUV_SHIFT 808 libswscale/utils.c c->input_rgb2yuv_table[RV_IDX] = ROUNDED_DIV((1 << RGB2YUV_SHIFT)*(V+Z) , Cv); RGB2YUV_SHIFT 809 libswscale/utils.c c->input_rgb2yuv_table[GV_IDX] = -ROUNDED_DIV((1 << RGB2YUV_SHIFT)*ONE*ONE , Cv); RGB2YUV_SHIFT 810 libswscale/utils.c c->input_rgb2yuv_table[BV_IDX] = ROUNDED_DIV((1 << RGB2YUV_SHIFT)*W , Cv); RGB2YUV_SHIFT 813 libswscale/utils.c c->input_rgb2yuv_table[BY_IDX] = ((int)(0.114 * 219 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 814 libswscale/utils.c c->input_rgb2yuv_table[BV_IDX] = (-(int)(0.081 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 815 libswscale/utils.c c->input_rgb2yuv_table[BU_IDX] = ((int)(0.500 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 816 libswscale/utils.c c->input_rgb2yuv_table[GY_IDX] = ((int)(0.587 * 219 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 817 libswscale/utils.c c->input_rgb2yuv_table[GV_IDX] = (-(int)(0.419 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 818 libswscale/utils.c c->input_rgb2yuv_table[GU_IDX] = (-(int)(0.331 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 819 libswscale/utils.c c->input_rgb2yuv_table[RY_IDX] = ((int)(0.299 * 219 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 820 libswscale/utils.c c->input_rgb2yuv_table[RV_IDX] = ((int)(0.500 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 821 libswscale/utils.c c->input_rgb2yuv_table[RU_IDX] = (-(int)(0.169 * 224 / 255 * (1 << RGB2YUV_SHIFT) + 0.5)); RGB2YUV_SHIFT 82 libswscale/x86/rgb2rgb.c #define BY ((int)( 0.098*(1<<RGB2YUV_SHIFT)+0.5)) RGB2YUV_SHIFT 83 libswscale/x86/rgb2rgb.c #define BV ((int)(-0.071*(1<<RGB2YUV_SHIFT)+0.5)) RGB2YUV_SHIFT 84 libswscale/x86/rgb2rgb.c #define BU ((int)( 0.439*(1<<RGB2YUV_SHIFT)+0.5)) RGB2YUV_SHIFT 85 libswscale/x86/rgb2rgb.c #define GY ((int)( 0.504*(1<<RGB2YUV_SHIFT)+0.5)) RGB2YUV_SHIFT 86 libswscale/x86/rgb2rgb.c #define GV ((int)(-0.368*(1<<RGB2YUV_SHIFT)+0.5)) RGB2YUV_SHIFT 87 libswscale/x86/rgb2rgb.c #define GU ((int)(-0.291*(1<<RGB2YUV_SHIFT)+0.5)) RGB2YUV_SHIFT 88 libswscale/x86/rgb2rgb.c #define RY ((int)( 0.257*(1<<RGB2YUV_SHIFT)+0.5)) RGB2YUV_SHIFT 89 libswscale/x86/rgb2rgb.c #define RV ((int)( 0.439*(1<<RGB2YUV_SHIFT)+0.5)) RGB2YUV_SHIFT 90 libswscale/x86/rgb2rgb.c #define RU ((int)(-0.148*(1<<RGB2YUV_SHIFT)+0.5))