Mercurial > libavcodec.hg
comparison imgconvert.c @ 1028:e76fb91de4cc libavcodec
reversing my own stupidity ... (raw packed yuv422 files dont use YUY2 but UYVY)
author | michaelni |
---|---|
date | Thu, 23 Jan 2003 01:20:47 +0000 |
parents | e61be5796027 |
children | 19de1445beb2 |
comparison
equal
deleted
inserted
replaced
1027:a0a7149be543 | 1028:e76fb91de4cc |
---|---|
240 cr = dst->data[2]; | 240 cr = dst->data[2]; |
241 p = src->data[0]; | 241 p = src->data[0]; |
242 | 242 |
243 for(y=0;y<height;y+=2) { | 243 for(y=0;y<height;y+=2) { |
244 for(x=0;x<width;x+=2) { | 244 for(x=0;x<width;x+=2) { |
245 cb[0] = p[0]; | 245 lum[0] = p[0]; |
246 lum[0] = p[1]; | 246 cb[0] = p[1]; |
247 cr[0] = p[2]; | 247 lum[1] = p[2]; |
248 lum[1] = p[3]; | 248 cr[0] = p[3]; |
249 p += 4; | 249 p += 4; |
250 lum += 2; | 250 lum += 2; |
251 cb++; | 251 cb++; |
252 cr++; | 252 cr++; |
253 } | 253 } |
254 for(x=0;x<width;x+=2) { | 254 for(x=0;x<width;x+=2) { |
255 lum[0] = p[1]; | 255 lum[0] = p[0]; |
256 lum[1] = p[3]; | 256 lum[1] = p[2]; |
257 p += 4; | 257 p += 4; |
258 lum += 2; | 258 lum += 2; |
259 } | 259 } |
260 } | 260 } |
261 } | 261 } |