This function obtains information about the specified file without loading the pixel data. This is an obsolete function, see remarks.
Declaration:
Copy Code | |
---|---|
AT_ERRCOUNT ACCUAPI IG_info_get(
const LPSTR lpszFileName,
LPAT_MODE lpFileType,
LPAT_MODE lpCompression,
LPAT_DIB lpDIB
);
|
Arguments:
lpszFileName | Name of file about which to get information. |
lpFileType | Pointer to an AT_MODE variable in which the file type will be returned. See enumIGFormats for possible values. |
lpCompression | Pointer to an AT_MODE variable in which compression type will be returned. See enumIGCompressions for possible values. |
lpDIB | Pointer to an AT_DIB structure to which additional file information such as width, height, and Bits Per Pixel will be returned. |
Return Value:
Returns 0 if successful. Otherwise, returns the number of ImageGear errors that occurred during this function call.Supported Raster Image Formats:
If lpDIB is not NULL, then
- Indexed RGB - 1, 4, 8 bpp;
- Grayscale - 9...16 bpp;
- RGB - 24 bpp;
- CMYK - 32 bpp.
otherwise, all pixel formats supported by ImageGear Professional.
Example:
Copy Code | |
---|---|
AT_MODE nFileType; // Will receive an IG_FORMAT_ constant AT_MODE nCompression; // Will receive an IG_COMPRESSION_ constant AT_DIB dibInfoDIB; // Will receive copy of the BITMAPINFOHEADER AT_ERRCOUNT nErrcount; // Returned count of errors nErrcount = IG_info_get("picture.bmp", &nFileType, &nCompression, &dibInfoDIB); |
Sample:
Filters, Processing, Paledit, Vector
Remarks:
This function is only kept for backward compatibility reasons. Please use IG_info_get_ex instead.
Any of the output parameters such as lpFileType, lpCompression or lpDIB can be NULL, if the corresponding info is not required.