SDL_HWPALETTE fix (submitted by tehpola)
This commit is contained in:
parent
9b4b52aba7
commit
b32c91e970
|
@ -281,9 +281,9 @@ SDL_Surface *WII_SetVideoMode(_THIS, SDL_Surface *current,
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(bpp != 8 && bpp != 16 && bpp != 24 && bpp != 32)
|
if(bpp != 8 && bpp != 16 && bpp != 24)
|
||||||
{
|
{
|
||||||
SDL_SetError("Resolution (%d bpp) is unsupported (8 or 16 bpp only).",
|
SDL_SetError("Resolution (%d bpp) is unsupported (8/16/24 bpp only).",
|
||||||
bpp);
|
bpp);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
@ -319,7 +319,7 @@ SDL_Surface *WII_SetVideoMode(_THIS, SDL_Surface *current,
|
||||||
SDL_memset(this->hidden->buffer, 0, width * height * bytes_per_pixel);
|
SDL_memset(this->hidden->buffer, 0, width * height * bytes_per_pixel);
|
||||||
|
|
||||||
// Set up the new mode framebuffer
|
// Set up the new mode framebuffer
|
||||||
current->flags = SDL_DOUBLEBUF |( flags & SDL_FULLSCREEN);
|
current->flags = SDL_DOUBLEBUF | (flags & SDL_FULLSCREEN) | (flags & SDL_HWPALETTE);
|
||||||
current->w = width;
|
current->w = width;
|
||||||
current->h = height;
|
current->h = height;
|
||||||
current->pitch = current->w * bytes_per_pixel;
|
current->pitch = current->w * bytes_per_pixel;
|
||||||
|
|
Reference in a new issue