<div>Dear Vincent:<span style="line-height: 1.5;"> </span></div><div><div>The PixelFormat32bppRGB shuld be PixelFormat32bppARGB in the </div><div>test_GdipDrawImagePointsRectNeedResample function of <span style="line-height: 1.5;">my patch.</span></div><div><span style="line-height: 1.5;"><br></span></div><div>In test_GdipDrawImagePointsRectNeedResample,  the first src_pointf valuse is :</div><div>X=5.992676, src_pointf.Y=0.000000 when the destination pixel is(x=699,y=0),</div><div>and srcx=6.000000,srcy=0.000000,srcwidth=48.000000,srcheight=26.000000,</div><div><br></div><div>so the follow if statement will test false :</div><div>if (src_pointf.X >= srcx && src_pointf.X < srcx + srcwidth && src_pointf.Y >= srcy && src_pointf.Y < srcy+srcheight)</div><div><br></div><div>then the destination pixel (x=699,y=0) will be filled with zero value,</div><div>but we expect that pixel shoule be filled a color same as the source image.</div><div><br></div><div>I think make these variables:</div><div>dst_to_src_points, src_pointf, x_dx, x_dy, y_dx, y_dy all use 64bit double float type maybe can fixed this situation. </div><div>But GpointF and GpMatrix has used 32bit float type, and many gdiplus functions depended on them.</div><div><br></div><div>Can you give me some advice ? Thank you!</div></div><div><includetail><div> </div><div> </div><div style="font:Verdana normal 14px;color:#000;"><div style="FONT-SIZE: 12px;FONT-FAMILY: Arial Narrow;padding:2px 0 2px 0;">------------------ Original ------------------</div><div style="FONT-SIZE: 12px;background:#efefef;padding:8px;"><div id="menu_sender"><b>From: </b> "Vincent Povirk"<madewokherd@gmail.com>;</div><div><b>Date: </b> Sun, Nov 23, 2014 12:57 PM</div><div><b>To: </b> "刘昌辉"<liuchanghui@linuxdeepin.com>; <wbr></div><div><b>Cc: </b> "Sebastian Lackner"<sebastian@fds-team.de>; "wine-devel"<wine-devel@winehq.org>; <wbr></div><div><b>Subject: </b> Re: gdiplus:GdipDrawImagePointsRect has a nosie vertical lineoutputafter resampled</div></div><div> </div>This will cause us to draw outside of the destination when the image<br>is both enlarged and rotated.<br><br>That if statement is there to make sure we only draw to the area<br>inside the shape defined by the points array. src_pointf should be<br>within the range defined by srcx/srcy/srcwidth/srcheight if and only<br>if (x,y) is within that shape. If that's not the case, it probably<br>means we're calculating src_pointf incorrectly for the whole image,<br>not just the edges.<br><br>I'm not sure Sebastian realized this, but in this case<br>GdipBitmapGetPixel is different from reading the image directly.<br>Because PixelFormat32bppRGB does not store alpha data in the bitmap,<br>GdipBitmapGetPixel will always return an alpha value of 255, and you<br>will get a non-zero value even if the pixel is black. I suggest<br>testing for the exact value you expect. That should also remove the<br>need for the trace() calls.<br></div><!--<![endif]--></includetail></div>