ImageGear Professional v18.2 > API Reference Guide > Core Component API Reference > Core Component Functions Reference > Load Functions > IG_load_rect_set |
This function sets the load rectangle.
Copy Code
|
|
---|---|
AT_ERRCOUNT ACCUAPI IG_load_rect_set( AT_PIXPOS nX, AT_PIXPOS nY, AT_DIMENSION nWidth, AT_DIMENSION nHeight ); |
Name | Type | Description |
nX | AT_PIXPOS | X coordinate of load rectangle. |
nY | AT_PIXPOS | Y coordinate of load rectangle. |
nWidth | AT_DIMENSION | Width of load rectangle. |
nHeight | AT_DIMENSION | Height of load rectangle. |
This function does not process image pixels.
Copy Code
|
|
---|---|
/* Set to only load the upper left 1000 x 500 of the image: */
IG_load_rect_set ( 0, 0, 1000, 500 );
|
This function will cause an image loaded to be cropped. Portions of the image falling outside the coordinates of this rectangle will be discarded, and will not appear in the image bitmap of the DIB created by the load.
To reset ImageGear to its default behavior of loading the whole image, set all parameters to 0. See also IG_load_rect_get function. |