Mercurial > mplayer.hg
comparison postproc/swscale.c @ 2267:3df32dabe98c
fixed a bug which caused horizontal lines
author | michael |
---|---|
date | Fri, 19 Oct 2001 00:21:07 +0000 |
parents | 7851375ea156 |
children | 95c48204bcd9 |
comparison
equal
deleted
inserted
replaced
2266:c2ed1e5742ed | 2267:3df32dabe98c |
---|---|
252 unsigned char *dest=dstptr+dststride*s_ypos; | 252 unsigned char *dest=dstptr+dststride*s_ypos; |
253 int y0=(s_srcypos + 0xFFFF)>>16; // first luminance source line number below the dst line | 253 int y0=(s_srcypos + 0xFFFF)>>16; // first luminance source line number below the dst line |
254 // points to the dst Pixels center in the source (0 is the center of pixel 0,0 in src) | 254 // points to the dst Pixels center in the source (0 is the center of pixel 0,0 in src) |
255 int srcuvpos= s_srcypos + s_yinc/2 - 0x8000; | 255 int srcuvpos= s_srcypos + s_yinc/2 - 0x8000; |
256 int y1=(srcuvpos + 0x1FFFF)>>17; // first chrominance source line number below the dst line | 256 int y1=(srcuvpos + 0x1FFFF)>>17; // first chrominance source line number below the dst line |
257 int yalpha=(s_srcypos&0xFFFF)>>7; | 257 int yalpha=((s_srcypos-1)&0xFFFF)>>7; |
258 int yalpha1=yalpha^511; | 258 int yalpha1=yalpha^511; |
259 int uvalpha=(srcuvpos&0x1FFFF)>>8; | 259 int uvalpha=((srcuvpos-1)&0x1FFFF)>>8; |
260 int uvalpha1=uvalpha^511; | 260 int uvalpha1=uvalpha^511; |
261 uint16_t *buf0=pix_buf_y[y0&1]; // top line of the interpolated slice | 261 uint16_t *buf0=pix_buf_y[y0&1]; // top line of the interpolated slice |
262 uint16_t *buf1=pix_buf_y[((y0+1)&1)]; // bottom line of the interpolated slice | 262 uint16_t *buf1=pix_buf_y[((y0+1)&1)]; // bottom line of the interpolated slice |
263 uint16_t *uvbuf0=pix_buf_uv[y1&1]; // top line of the interpolated slice | 263 uint16_t *uvbuf0=pix_buf_uv[y1&1]; // top line of the interpolated slice |
264 uint16_t *uvbuf1=pix_buf_uv[(y1+1)&1]; // bottom line of the interpolated slice | 264 uint16_t *uvbuf1=pix_buf_uv[(y1+1)&1]; // bottom line of the interpolated slice |