winex11.drv: SetDIBits fails when startscan != 0

Massimo Del Fedele max at veneto.com
Sat Mar 14 07:57:16 CDT 2009


---
 dlls/winex11.drv/dib.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/winex11.drv/dib.c b/dlls/winex11.drv/dib.c
index 6df4137..6817f7a 100644
--- a/dlls/winex11.drv/dib.c
+++ b/dlls/winex11.drv/dib.c
@@ -3977,7 +3977,7 @@ INT CDECL X11DRV_SetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT start
        default: break;
   }
 
-  descr.bits      = bits;
+  descr.bits      = (BYTE *)bits + ds.dsBm.bmWidthBytes * (tmpheight > 0 ? (height - startscan - lines) : startscan);
   descr.image     = NULL;
   descr.palentry  = NULL;
   descr.infoWidth = width;
@@ -3988,7 +3988,7 @@ INT CDECL X11DRV_SetDIBits( X11DRV_PDEVICE *physDev, HBITMAP hbitmap, UINT start
   descr.xSrc      = 0;
   descr.ySrc      = 0;
   descr.xDest     = 0;
-  descr.yDest     = height - startscan - lines;
+  descr.yDest     = 0;
   descr.width     = ds.dsBm.bmWidth;
   descr.height    = lines;
   descr.useShm    = FALSE;
-- 
1.5.6.3


--------------060700010504060306000608--




More information about the wine-patches mailing list