# HG changeset patch # User michael # Date 1003450867 0 # Node ID 3df32dabe98c66f20a46f96d4b13e55a2ff5e18c # Parent c2ed1e5742ed8443d7f1ac8975d2ae3bf02b445d fixed a bug which caused horizontal lines diff -r c2ed1e5742ed -r 3df32dabe98c postproc/swscale.c --- a/postproc/swscale.c Fri Oct 19 00:16:13 2001 +0000 +++ b/postproc/swscale.c Fri Oct 19 00:21:07 2001 +0000 @@ -254,9 +254,9 @@ // points to the dst Pixels center in the source (0 is the center of pixel 0,0 in src) int srcuvpos= s_srcypos + s_yinc/2 - 0x8000; int y1=(srcuvpos + 0x1FFFF)>>17; // first chrominance source line number below the dst line - int yalpha=(s_srcypos&0xFFFF)>>7; + int yalpha=((s_srcypos-1)&0xFFFF)>>7; int yalpha1=yalpha^511; - int uvalpha=(srcuvpos&0x1FFFF)>>8; + int uvalpha=((srcuvpos-1)&0x1FFFF)>>8; int uvalpha1=uvalpha^511; uint16_t *buf0=pix_buf_y[y0&1]; // top line of the interpolated slice uint16_t *buf1=pix_buf_y[((y0+1)&1)]; // bottom line of the interpolated slice diff -r c2ed1e5742ed -r 3df32dabe98c postproc/swscale_template.c --- a/postproc/swscale_template.c Fri Oct 19 00:16:13 2001 +0000 +++ b/postproc/swscale_template.c Fri Oct 19 00:21:07 2001 +0000 @@ -254,9 +254,9 @@ // points to the dst Pixels center in the source (0 is the center of pixel 0,0 in src) int srcuvpos= s_srcypos + s_yinc/2 - 0x8000; int y1=(srcuvpos + 0x1FFFF)>>17; // first chrominance source line number below the dst line - int yalpha=(s_srcypos&0xFFFF)>>7; + int yalpha=((s_srcypos-1)&0xFFFF)>>7; int yalpha1=yalpha^511; - int uvalpha=(srcuvpos&0x1FFFF)>>8; + int uvalpha=((srcuvpos-1)&0x1FFFF)>>8; int uvalpha1=uvalpha^511; uint16_t *buf0=pix_buf_y[y0&1]; // top line of the interpolated slice uint16_t *buf1=pix_buf_y[((y0+1)&1)]; // bottom line of the interpolated slice