From ad029665352aadb6536ed18736f292bef7acd5e4 Mon Sep 17 00:00:00 2001 From: Patrice Mandin Date: Tue, 3 Aug 2004 08:50:52 +0000 Subject: [PATCH] Wrongly test if width multiple of 16 --- src/video/gem/SDL_gemvideo.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/video/gem/SDL_gemvideo.c b/src/video/gem/SDL_gemvideo.c index 97020fb66..28dce28da 100644 --- a/src/video/gem/SDL_gemvideo.c +++ b/src/video/gem/SDL_gemvideo.c @@ -563,7 +563,7 @@ SDL_Surface *GEM_SetVideoMode(_THIS, SDL_Surface *current, } /* width must be multiple of 16, for vro_cpyfm() and c2p_convert() */ - if ((width & -16) != 0) { + if ((width & 15) != 0) { width = (width | 15) +1; } @@ -749,7 +749,7 @@ static void GEM_UpdateRectsFullscreen(_THIS, int numrects, SDL_Rect *rects) surface = this->screen; /* Need to be a multiple of 16 pixels */ surf_width=surface->w; - if ((surf_width & -16) != 0) { + if ((surf_width & 15) != 0) { surf_width = (surf_width | 15) + 1; } @@ -869,7 +869,7 @@ static int GEM_FlipHWSurfaceFullscreen(_THIS, SDL_Surface *surface) /* Need to be a multiple of 16 pixels */ surf_width=surface->w; - if ((surf_width & -16) != 0) { + if ((surf_width & 15) != 0) { surf_width = (surf_width | 15) + 1; } @@ -1200,7 +1200,7 @@ static void refresh_window(_THIS, int winhandle, short *rect) /* Need to be a multiple of 16 pixels */ width=surface->w; - if ((width & -16) != 0) { + if ((width & 15) != 0) { width = (width | 15) + 1; } mfdb_src.fd_w=width;