changeset 11:2105d2dfefa3

Try to adjust blitting with SDL surface pitch. Might fix something.
author Matti Hamalainen <ccr@tnsp.org>
date Tue, 18 May 2010 18:47:16 +0300
parents a379d6a2a717
children 18e14722f58a
files pwplib/sdl.c
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/pwplib/sdl.c	Tue May 18 17:58:37 2010 +0300
+++ b/pwplib/sdl.c	Tue May 18 18:47:16 2010 +0300
@@ -51,6 +51,9 @@
         j = (j + 1) & 1;
         if (!j)
             ss += pwplib.videobuf.width;
+        
+        if (pwp_SDL.screen->pitch > pwp_SDL.screen->w)
+            d += pwp_SDL.screen->pitch - pwp_SDL.screen->w;
     }
 
     if (SDL_MUSTLOCK(pwp_SDL.screen) != 0)