This function resizes the image referenced by hIGear without scaling it.
Declaration:
Copy Code | |
---|---|
AT_ERRCOUNT LACCUAPI IG_IP_resize_canvas( HIGEAR hIGear, AT_DIMENSION new_width, AT_DIMENSION new_height, AT_PIXPOS nXPos, AT_PIXPOS nYPos, LPAT_PIXEL lpBkgColor ); |
Arguments:
hIGear | Image to process. |
new_width | Width of the image after resizing. |
new_height | Height of the image after resizing. |
nXPos | X offset at which to put left top corner of the image after resizing. |
nYPos | Y offset at which to put left top corner of the image after resizing. |
lpBkgColor | Color with which to fill the empty area. |
Return Value:
Returns 0 if successful. Otherwise, returns the number of ImageGear errors that occurred during this function call.Supported Raster Image Formats:
All pixel formats supported by ImageGear Professional.
Sample:
See GUI component source code.
Remarks:
The image data in the bitmap is not stretched or compressed, but copied to the specified offset in the new image.