From 2cd9f5c9d0363eb95de5cf18041ddbeeeee33fa9 Mon Sep 17 00:00:00 2001 From: Lee Salzman Date: Sat, 6 Feb 2010 02:53:44 +0000 Subject: [PATCH] force 32 bpp surfaces to 24 bpp if no alpha git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4781 e016b1c5-ed68-44aa-a2f7-31cac88cffde --- source/src/texture.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/src/texture.cpp b/source/src/texture.cpp index 70735d9d..6140fe6a 100644 --- a/source/src/texture.cpp +++ b/source/src/texture.cpp @@ -231,7 +231,7 @@ SDL_Surface *fixsurfaceformat(SDL_Surface *s) break; case 4: if(s->format->Rmask != rgbamasks[0] || s->format->Gmask != rgbamasks[1] || s->format->Bmask != rgbamasks[2] || s->format->Amask != rgbamasks[3]) - return forcergbasurface(s); + return s->format->Amask ? forgergbasurface(s) : forgergbsurface(s); break; } return s;