Tao.Sdl SDK Documentation

SdlImage.IMG_isXCF Method 

Test for valid, supported XCF file.

[Visual Basic]
Public Shared Function IMG_isXCF( _
   ByVal src As IntPtr _
) As IntPtr
[C#]
public static IntPtr IMG_isXCF(
   IntPtr src
);

Parameters

src

Return Value

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

Remarks

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

Binds to C-function in SDL_image.h

            int IMG_isXCF(SDL_RWops *src)
            

Example

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

See Also

SdlImage Class | Tao.Sdl Namespace | IMG_LoadTyped_RW