Mercurial > sdl-ios-xcode
diff include/SDL_video.h @ 4173:34068be6aa0b SDL-1.2
Fixed bug #421
Comment #3 From esigra@gmail.com 2008-04-09 11:46:46 (-) [reply] -------
This bug also needs to be fixed for SDL_GetRGB and SDL_GetRGBA (those should
not change the format of the surface either). Until this is fixed, I still need
to const_cast the format parameter in calls to those functions.
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Mon, 13 Apr 2009 09:03:35 +0000 |
parents | a1b03ba2fcd0 |
children | 4c4113c2162c |
line wrap: on
line diff
--- a/include/SDL_video.h Mon Apr 13 08:49:41 2009 +0000 +++ b/include/SDL_video.h Mon Apr 13 09:03:35 2009 +0000 @@ -460,14 +460,16 @@ /* * Maps a pixel value into the RGB components for a given pixel format */ -extern DECLSPEC void SDLCALL SDL_GetRGB(Uint32 pixel, SDL_PixelFormat *fmt, +extern DECLSPEC void SDLCALL SDL_GetRGB(Uint32 pixel, + const SDL_PixelFormat * const fmt, Uint8 *r, Uint8 *g, Uint8 *b); /* * Maps a pixel value into the RGBA components for a given pixel format */ -extern DECLSPEC void SDLCALL SDL_GetRGBA(Uint32 pixel, SDL_PixelFormat *fmt, - Uint8 *r, Uint8 *g, Uint8 *b, Uint8 *a); +extern DECLSPEC void SDLCALL SDL_GetRGBA(Uint32 pixel, + const SDL_PixelFormat * const fmt, + Uint8 *r, Uint8 *g, Uint8 *b, Uint8 *a); /* * Allocate and free an RGB surface (must be called after SDL_SetVideoMode)