ImageGear Professional for Linux
IG_IP_draw_frame

This function adds a frame (block of solid color on all four sides) to the image referenced by hIGear.

Declaration:

 
Copy Code
AT_ERRCOUNT ACCUAPI IG_IP_draw_frame ( 
        HIGEAR hIGear, 
        AT_DIMENSION width, 
        AT_MODE nMethod, 
        LPAT_PIXEL lpColor 
);

Arguments:

Name Type Description
hIGear HIGEAR HIGEAR handle of image.
width AT_DIMENSION A variable that holds the width of the frame, in pixels.
nMethod AT_MODE A variable of type AT_MODE that tells ImageGear which IG_DRAW_FRAME_ setting to use. See Remarks.
lpColor LPAT_PIXEL A far pointer to the RGB value that specifies the frame's color.

Return Value:

Returns the number of ImageGear errors that occurred during this function call.

Supported Raster Image Formats:

All pixel formats supported by ImageGear Professional.

Example:

 
Copy Code
HIGEAR hIGear; /* HIGEAR handle of image */
AT_ERRCOUNT nErrcount;  /* holds tally of IG errors */
AT_DIMENSION width;  /* width, in pixels, of frame  */
AT_MODE          nMethod;  /* expand or overwrite image  */
AT_PIXEL lpColor[256];  /* color of frame; RGB value  */
nErrcount = IG_IP_draw_frame ( hIGear, 5, IG_DRAW_FRAME_EXPAND, &lpColor[9]);

Remarks:

If nMethod is set to IG_DRAW_FRAME_EXPAND, the width and the height of the image will be expanded by 2 times the width of the frame. If nMethod is set to IG_DRAW_FRAME_OVERWRITE, all four sides of the image will be overwritten by the frame, so that the resulting image has the same width and height as the original image, but the edges of the image are "covered" by the frame.

 

 


©2016. Accusoft Corporation. All Rights Reserved.

Send Feedback