SDL_image.h
changeset 64 ee887f68af8e
parent 53 96b084473b47
child 89 9a1b32277af8
equal deleted inserted replaced
63:8206b61bfb62 64:ee887f68af8e
    41    If the image format supports a transparent pixel, SDL will set the
    41    If the image format supports a transparent pixel, SDL will set the
    42    colorkey for the surface.  You can enable RLE acceleration on the
    42    colorkey for the surface.  You can enable RLE acceleration on the
    43    surface afterwards by calling:
    43    surface afterwards by calling:
    44 	SDL_SetColorKey(image, SDL_RLEACCEL, image->format->colorkey);
    44 	SDL_SetColorKey(image, SDL_RLEACCEL, image->format->colorkey);
    45  */
    45  */
    46 extern DECLSPEC SDL_Surface *IMG_LoadTyped_RW(SDL_RWops *src, int freesrc,
    46 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadTyped_RW(SDL_RWops *src, int freesrc, char *type);
    47 					      char *type);
       
    48 /* Convenience functions */
    47 /* Convenience functions */
    49 extern DECLSPEC SDL_Surface *IMG_Load(const char *file);
    48 extern DECLSPEC SDL_Surface * SDLCALL IMG_Load(const char *file);
    50 extern DECLSPEC SDL_Surface *IMG_Load_RW(SDL_RWops *src, int freesrc);
    49 extern DECLSPEC SDL_Surface * SDLCALL IMG_Load_RW(SDL_RWops *src, int freesrc);
    51 
    50 
    52 /* Invert the alpha of a surface for use with OpenGL
    51 /* Invert the alpha of a surface for use with OpenGL
    53    This function is now a no-op, and only provided for backwards compatibility.
    52    This function is now a no-op, and only provided for backwards compatibility.
    54 */
    53 */
    55 extern DECLSPEC int IMG_InvertAlpha(int on);
    54 extern DECLSPEC int SDLCALL IMG_InvertAlpha(int on);
    56 
    55 
    57 /* Functions to detect a file type, given a seekable source */
    56 /* Functions to detect a file type, given a seekable source */
    58 extern DECLSPEC int IMG_isBMP(SDL_RWops *src);
    57 extern DECLSPEC int SDLCALL IMG_isBMP(SDL_RWops *src);
    59 extern DECLSPEC int IMG_isPNM(SDL_RWops *src);
    58 extern DECLSPEC int SDLCALL IMG_isPNM(SDL_RWops *src);
    60 extern DECLSPEC int IMG_isXPM(SDL_RWops *src);
    59 extern DECLSPEC int SDLCALL IMG_isXPM(SDL_RWops *src);
    61 extern DECLSPEC int IMG_isXCF(SDL_RWops *src);
    60 extern DECLSPEC int SDLCALL IMG_isXCF(SDL_RWops *src);
    62 extern DECLSPEC int IMG_isPCX(SDL_RWops *src);
    61 extern DECLSPEC int SDLCALL IMG_isPCX(SDL_RWops *src);
    63 extern DECLSPEC int IMG_isGIF(SDL_RWops *src);
    62 extern DECLSPEC int SDLCALL IMG_isGIF(SDL_RWops *src);
    64 extern DECLSPEC int IMG_isJPG(SDL_RWops *src);
    63 extern DECLSPEC int SDLCALL IMG_isJPG(SDL_RWops *src);
    65 extern DECLSPEC int IMG_isTIF(SDL_RWops *src);
    64 extern DECLSPEC int SDLCALL IMG_isTIF(SDL_RWops *src);
    66 extern DECLSPEC int IMG_isPNG(SDL_RWops *src);
    65 extern DECLSPEC int SDLCALL IMG_isPNG(SDL_RWops *src);
    67 extern DECLSPEC int IMG_isLBM(SDL_RWops *src);
    66 extern DECLSPEC int SDLCALL IMG_isLBM(SDL_RWops *src);
    68 
    67 
    69 /* Individual loading functions */
    68 /* Individual loading functions */
    70 extern DECLSPEC SDL_Surface *IMG_LoadBMP_RW(SDL_RWops *src);
    69 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadBMP_RW(SDL_RWops *src);
    71 extern DECLSPEC SDL_Surface *IMG_LoadPNM_RW(SDL_RWops *src);
    70 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadPNM_RW(SDL_RWops *src);
    72 extern DECLSPEC SDL_Surface *IMG_LoadXPM_RW(SDL_RWops *src);
    71 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadXPM_RW(SDL_RWops *src);
    73 extern DECLSPEC SDL_Surface *IMG_LoadXCF_RW(SDL_RWops *src);
    72 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadXCF_RW(SDL_RWops *src);
    74 extern DECLSPEC SDL_Surface *IMG_LoadPCX_RW(SDL_RWops *src);
    73 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadPCX_RW(SDL_RWops *src);
    75 extern DECLSPEC SDL_Surface *IMG_LoadGIF_RW(SDL_RWops *src);
    74 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadGIF_RW(SDL_RWops *src);
    76 extern DECLSPEC SDL_Surface *IMG_LoadJPG_RW(SDL_RWops *src);
    75 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadJPG_RW(SDL_RWops *src);
    77 extern DECLSPEC SDL_Surface *IMG_LoadTIF_RW(SDL_RWops *src);
    76 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadTIF_RW(SDL_RWops *src);
    78 extern DECLSPEC SDL_Surface *IMG_LoadPNG_RW(SDL_RWops *src);
    77 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadPNG_RW(SDL_RWops *src);
    79 extern DECLSPEC SDL_Surface *IMG_LoadTGA_RW(SDL_RWops *src);
    78 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadTGA_RW(SDL_RWops *src);
    80 extern DECLSPEC SDL_Surface *IMG_LoadLBM_RW(SDL_RWops *src);
    79 extern DECLSPEC SDL_Surface * SDLCALL IMG_LoadLBM_RW(SDL_RWops *src);
    81 
    80 
    82 extern DECLSPEC SDL_Surface *IMG_ReadXPMFromArray(char **xpm);
    81 extern DECLSPEC SDL_Surface * SDLCALL IMG_ReadXPMFromArray(char **xpm);
    83 
    82 
    84 /* We'll use SDL for reporting errors */
    83 /* We'll use SDL for reporting errors */
    85 #define IMG_SetError	SDL_SetError
    84 #define IMG_SetError	SDL_SetError
    86 #define IMG_GetError	SDL_GetError
    85 #define IMG_GetError	SDL_GetError
    87 
    86