From: Michael Niedermayer Date: Mon, 17 Jun 2002 17:12:22 +0000 (+0000) Subject: 10l X-Git-Tag: v0.5~17599 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f0063c1a5b199c3e504c7539e5078d6c2e9242ba;p=platform%2Fupstream%2Flibav.git 10l Originally committed as revision 6459 to svn://svn.mplayerhq.hu/mplayer/trunk/postproc --- diff --git a/postproc/yuv2rgb.c b/postproc/yuv2rgb.c index 85c7570..08ebc1a 100644 --- a/postproc/yuv2rgb.c +++ b/postproc/yuv2rgb.c @@ -50,6 +50,39 @@ #define CAN_COMPILE_X86_ASM #endif +uint8_t __attribute__((aligned(8))) dither_8x8_32[8][8]={ +{ 17, 9, 23, 15, 16, 8, 22, 14, }, +{ 5, 29, 3, 27, 4, 28, 2, 26, }, +{ 21, 13, 19, 11, 20, 12, 18, 10, }, +{ 0, 24, 6, 30, 1, 25, 7, 31, }, +{ 16, 8, 22, 14, 17, 9, 23, 15, }, +{ 4, 28, 2, 26, 5, 29, 3, 27, }, +{ 20, 12, 18, 10, 21, 13, 19, 11, }, +{ 1, 25, 7, 31, 0, 24, 6, 30, }, +}; + +uint8_t __attribute__((aligned(8))) dither_8x8_64[8][8]={ +{ 0, 48, 12, 60, 3, 51, 15, 63, }, +{ 32, 16, 44, 28, 35, 19, 47, 31, }, +{ 8, 56, 4, 52, 11, 59, 7, 55, }, +{ 40, 24, 36, 20, 43, 27, 39, 23, }, +{ 2, 50, 14, 62, 1, 49, 13, 61, }, +{ 34, 18, 46, 30, 33, 17, 45, 29, }, +{ 10, 58, 6, 54, 9, 57, 5, 53, }, +{ 42, 26, 38, 22, 41, 25, 37, 21, }, +}; + +uint8_t __attribute__((aligned(8))) dither_8x8_128[8][8]={ +{ 68, 36, 92, 60, 66, 34, 90, 58, }, +{ 20, 116, 12, 108, 18, 114, 10, 106, }, +{ 84, 52, 76, 44, 82, 50, 74, 42, }, +{ 0, 96, 24, 120, 6, 102, 30, 126, }, +{ 64, 32, 88, 56, 70, 38, 94, 62, }, +{ 16, 112, 8, 104, 22, 118, 14, 110, }, +{ 80, 48, 72, 40, 86, 54, 78, 46, }, +{ 4, 100, 28, 124, 2, 98, 26, 122, }, +}; + #ifdef CAN_COMPILE_X86_ASM /* hope these constant values are cache line aligned */ @@ -87,39 +120,6 @@ uint64_t __attribute__((aligned(8))) dither8[2]={ 0x0602060206020602LL, 0x0004000400040004LL,}; -uint8_t __attribute__((aligned(8))) dither_8x8_32[8][8]={ -{ 17, 9, 23, 15, 16, 8, 22, 14, }, -{ 5, 29, 3, 27, 4, 28, 2, 26, }, -{ 21, 13, 19, 11, 20, 12, 18, 10, }, -{ 0, 24, 6, 30, 1, 25, 7, 31, }, -{ 16, 8, 22, 14, 17, 9, 23, 15, }, -{ 4, 28, 2, 26, 5, 29, 3, 27, }, -{ 20, 12, 18, 10, 21, 13, 19, 11, }, -{ 1, 25, 7, 31, 0, 24, 6, 30, }, -}; - -uint8_t __attribute__((aligned(8))) dither_8x8_64[8][8]={ -{ 0, 48, 12, 60, 3, 51, 15, 63, }, -{ 32, 16, 44, 28, 35, 19, 47, 31, }, -{ 8, 56, 4, 52, 11, 59, 7, 55, }, -{ 40, 24, 36, 20, 43, 27, 39, 23, }, -{ 2, 50, 14, 62, 1, 49, 13, 61, }, -{ 34, 18, 46, 30, 33, 17, 45, 29, }, -{ 10, 58, 6, 54, 9, 57, 5, 53, }, -{ 42, 26, 38, 22, 41, 25, 37, 21, }, -}; - -uint8_t __attribute__((aligned(8))) dither_8x8_128[8][8]={ -{ 68, 36, 92, 60, 66, 34, 90, 58, }, -{ 20, 116, 12, 108, 18, 114, 10, 106, }, -{ 84, 52, 76, 44, 82, 50, 74, 42, }, -{ 0, 96, 24, 120, 6, 102, 30, 126, }, -{ 64, 32, 88, 56, 70, 38, 94, 62, }, -{ 16, 112, 8, 104, 22, 118, 14, 110, }, -{ 80, 48, 72, 40, 86, 54, 78, 46, }, -{ 4, 100, 28, 124, 2, 98, 26, 122, }, -}; - #undef HAVE_MMX #undef ARCH_X86 @@ -143,7 +143,6 @@ uint8_t __attribute__((aligned(8))) dither_8x8_128[8][8]={ #endif // CAN_COMPILE_X86_ASM - uint32_t matrix_coefficients = 6; const int32_t Inverse_Table_6_9[8][4] = {