[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

3.3.7 IMG_isPCX

int IMG_isPCX(SDL_RWops *src)

src

If the PCX format is supported, then the image data is tested to see if it is readable as a PCX, otherwise it returns false (Zero).

Returns: 1 if the image is a PCX and the PCX format support is compiled into SDL_image. 0 is returned otherwise.

 
// Test sample.pcx to see if it is a PCX
SDL_RWops *rwop;
rwop=SDL_RWFromFile("sample.pcx", "rb");
if(IMG_isPCX(rwop))
	printf("sample.pcx is a PCX file.\n");
else
	printf("sample.pcx is not a PCX file, or PCX support is not available.\n");

See Also:
3.2.10 IMG_LoadPCX_RW, 3.2.3 IMG_LoadTyped_RW



This document was generated on November, 3 2009 using texi2html