This function applies a shearing effect to an image, moving the image rasters or columns according to the specified offsets.
Declaration:
Copy Code | |
---|---|
AT_ERRCOUNT ACCUAPI IG_FX_shear( HIGEAR hIGear, AT_DOUBLE* curvePoints, AT_INT pointCount, enumIGIPShearFillStyle fillStyle, AT_BOOL interpolate, AT_BOOL vertical, HIGPIXEL hbkColor ); |
Arguments:
hIGear | Image to which to apply shear effect. |
curvePoints | The array of offsets to move the image by. Every offset is in the range -1 to 1. Negative values shift the raster/column to the left, while positive values shift it to the right. The number of offsets is equal to the image width or height depending on the direction of movement (horizontal or vertical). |
pointCount | Specifies curvePoints array length. |
fillStyle | Specifies how the empty image area is filled. See enumIGIPShearFillStyle. |
interpolate | If TRUE, interpolation is used to smooth shifted pixel values. |
vertical | If TRUE, the direction of motion is vertical. Otherwise, the direction is horizontal. |
hbkColor | Background color to use for filling empty image area. Only used if the specified fill style uses a fill color. It should have the same color space and channel depths as the image to which the effect is applied. |
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.
Sample:
Image Processing
Remarks:
The fillStyle parameter can be set to one of the following values:
Name | Description |
IG_IP_SHEAR_FILLCOLOR | Empty area is filled with the specified color. |
IG_IP_SHEAR_NOCHANGE | Empty area remains unchanged. |
IG_IP_SHEAR_REPEATEDGE | Empty area is filled with the first or last raster color. |
IG_IP_SHEAR_REPEATRASTER | The raster is repeated periodically across the empty area. |