ImageGear for C and C++ on Linux v20.0 - Updated
API Reference Guide > Core Component API Reference > Core Component Functions Reference > Multi Page Image Functions > IG_mpi_is_valid

This function is used for checking whether the hMIGear value is a valid multi-page image handle.


Copy Code
AT_BOOL ACCUAPI IG_mpi_is_valid( HMIGEAR hMIGear );


Name Type Description
hMIGear HMIGEAR Handle to allocated multi-page image.

Return Value:

Returns TRUE if the given multi-page image is valid.

Supported Raster Image Formats:

All pixel formats supported by ImageGear for C and C++.


Copy Code
HMIGEAR hMIGear;       /* handle to multi-page image */
AT_ERRCOUNT             nErrCount = IGE_SUCCESS; /* will hold returned error count */
nErrCount = IG_mpi_create( &hMIGear, 0 );
if ( IG_mpi_is_valid(hMIGear) )
        printf("The multi-page image is valid!");
        printf("It's not valid multi-page image!");
IG_mpi_delete( hMIGear );


The multi-page image is valid if the IG_mpi_create() function is returned successfully and IG_mpi_delete() has not been called.

Is this page helpful?
Yes No
Thanks for your feedback.