|
|
@ -1,4 +1,4 @@
|
|
|
|
/* $Id: gfxpixelimage.c,v 1.5 2004/01/03 22:32:18 stpohle Exp $ */
|
|
|
|
/* $Id: gfxpixelimage.c,v 1.6 2004/01/03 23:57:13 stpohle Exp $ */
|
|
|
|
/* gfx pixel manipulation and image manipulation */
|
|
|
|
/* gfx pixel manipulation and image manipulation */
|
|
|
|
|
|
|
|
|
|
|
|
#include "bomberclone.h"
|
|
|
|
#include "bomberclone.h"
|
|
|
@ -312,7 +312,9 @@ makegray_image (SDL_Surface * org)
|
|
|
|
bmask = 0x000000ff;
|
|
|
|
bmask = 0x000000ff;
|
|
|
|
amask = 0xff000000;
|
|
|
|
amask = 0xff000000;
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
dest = SDL_CreateRGBSurface (SDL_SWSURFACE, org->w, org->h, 32, rmask, gmask, bmask, amask);
|
|
|
|
dest = SDL_CreateRGBSurface (SDL_SWSURFACE, org->w, org->h, org->format->BitsPerPixel,
|
|
|
|
|
|
|
|
org->format->Rmask, org->format->Gmask,
|
|
|
|
|
|
|
|
org->format->Bmask, org->format->Amask);
|
|
|
|
if (dest == NULL) {
|
|
|
|
if (dest == NULL) {
|
|
|
|
fprintf (stderr, "CreateRGBSurface failed: %s\n", SDL_GetError ());
|
|
|
|
fprintf (stderr, "CreateRGBSurface failed: %s\n", SDL_GetError ());
|
|
|
|
return NULL;
|
|
|
|
return NULL;
|
|
|
|