Mercurial > mplayer.hg
comparison postproc/swscale.c @ 4612:4edfdec1dc12
bgr24toY in MMX
author | michael |
---|---|
date | Sat, 09 Feb 2002 17:03:53 +0000 |
parents | ee28f294cc48 |
children | ef213d64e20a |
comparison
equal
deleted
inserted
replaced
4611:7b793875a640 | 4612:4edfdec1dc12 |
---|---|
65 //#undef HAVE_MMX2 | 65 //#undef HAVE_MMX2 |
66 //#define HAVE_3DNOW | 66 //#define HAVE_3DNOW |
67 //#undef HAVE_MMX | 67 //#undef HAVE_MMX |
68 //#undef ARCH_X86 | 68 //#undef ARCH_X86 |
69 #define DITHER1XBPP | 69 #define DITHER1XBPP |
70 | |
71 #define FAST_BGR2YV12 // use 7 bit coeffs instead of 15bit | |
70 | 72 |
71 #define RET 0xC3 //near return opcode for X86 | 73 #define RET 0xC3 //near return opcode for X86 |
72 | 74 |
73 #ifdef MP_DEBUG | 75 #ifdef MP_DEBUG |
74 #define ASSERT(x) if(!(x)) { printf("ASSERT " #x " failed\n"); *((int*)0)=0; } | 76 #define ASSERT(x) if(!(x)) { printf("ASSERT " #x " failed\n"); *((int*)0)=0; } |
175 static uint64_t __attribute__((aligned(8))) r15Mask= 0x7C007C007C007C00LL; | 177 static uint64_t __attribute__((aligned(8))) r15Mask= 0x7C007C007C007C00LL; |
176 | 178 |
177 static uint64_t __attribute__((aligned(8))) M24A= 0x00FF0000FF0000FFLL; | 179 static uint64_t __attribute__((aligned(8))) M24A= 0x00FF0000FF0000FFLL; |
178 static uint64_t __attribute__((aligned(8))) M24B= 0xFF0000FF0000FF00LL; | 180 static uint64_t __attribute__((aligned(8))) M24B= 0xFF0000FF0000FF00LL; |
179 static uint64_t __attribute__((aligned(8))) M24C= 0x0000FF0000FF0000LL; | 181 static uint64_t __attribute__((aligned(8))) M24C= 0x0000FF0000FF0000LL; |
182 | |
183 #ifdef FAST_BGR2YV12 | |
184 static const uint64_t bgr2YCoeff __attribute__((aligned(8))) = 0x000000210041000DULL; | |
185 #else | |
186 static const uint64_t bgr2YCoeff __attribute__((aligned(8))) = 0x000020E540830C8BULL; | |
187 #endif | |
188 static const uint64_t bgr2YOffset __attribute__((aligned(8))) = 0x1010101010101010ULL; | |
189 static const uint64_t w1111 __attribute__((aligned(8))) = 0x0001000100010001ULL; | |
180 | 190 |
181 // FIXME remove | 191 // FIXME remove |
182 static uint64_t __attribute__((aligned(8))) asm_yalpha1; | 192 static uint64_t __attribute__((aligned(8))) asm_yalpha1; |
183 static uint64_t __attribute__((aligned(8))) asm_uvalpha1; | 193 static uint64_t __attribute__((aligned(8))) asm_uvalpha1; |
184 #endif | 194 #endif |