This function deletes the HIGEAR handle and all memory associated with it.
Copy Code
|
|
---|---|
AT_ERRCOUNT ACCUAPI IG_image_delete( HIGEAR hIGear ); |
Name | Type | Description |
---|---|---|
hIGear | HIGEAR | HIGEAR handle of image to delete. |
All pixel formats supported by ImageGear for C and C++.
All ImageGear DLL samples.
Copy Code
|
|
---|---|
// Create a new image with the same parameters as an existing image, // but with no pixel data allocated AT_ERRCOUNT nErrcount; // Number of errors on stack HIGEAR hIGear; // Handle of image // Load image file "picture.bmp" from working directory nErrcount = IG_load_file("picture.bmp", &hIGear); if(nErrcount == 0) { // ... // Destroy the image IG_image_delete(hIGear); } |
This function also frees the memory associated with the image's DIB, if ImageGear allocated the DIB memory. If ImageGear did not allocate the DIB memory, the DIB continues to exist, and it is the responsibility of your application to free this memory when done with it.