Documentation / Marblecore Imaging / Methods / Skew
Skew method
Performs a skew transformation on the current image.
Syntax
Boolean Skew(nLeftTopX As Number, nLeftTopY As Number, nLeftBottomX As Number, nLeftBottomY As Number, nRightTopX As Number, nRightTopY As Number, nRightBottomX As Number, nRightBottomY As Number, nBackgroundColor As Number, nBackgroundOpacity As Number)
Return value
Returns true if the function succeeded.
Parameters
Parameter | Type | Required | Description |
nLeftTopX | Number | Yes | Specifies the horizontal left top coordinate for the transformation. |
nLeftTopY | Number | Yes | Specifies the vertical left top coordinate for the transformation. |
nLeftBottomX | Number | No | Specifies the horizontal left bottom coordinate for the transformation. |
nLeftBottomY | Number | No | Specifies the vertical left bottom coordinate for the transformation. |
nRightTopX | Number | No | Specifies the horizontal right top coordinate for the transformation. |
nRightTopY | Number | No | Specifies the vertical right top coordinate for the transformation. |
nRightBottomX | Number | No | Specifies the horizontal right bottom coordinate for the transformation. |
nRightBottomY | Number | No | Specifies the vertical right bottom coordinate for the transformation. |
nBackgroundColor | Number | No | Optional parameter containing the background color. If no color is specified the current background color will be used. |
nBackgroundOpacity | Number | No | Optional parameter containing the background opacity. |
Example
The example below shows the effect of this method and how to use it. You can slide the marker in the before/after picture to see the difference. If you take a look at the example code, assume there is a reference to the Marblecore Imaging object with the name 'MarblecoreImaging'. Transparent parts of the image are displayed using a checkerboard pattern.
1
2 MarblecoreImaging.LoadFromFile("example-skew-before.jpg");
3
4
5 MarblecoreImaging.Skew(60, 0, 0, 533, 760, 60, 750, 463);
6
7
8 MarblecoreImaging.SaveToFile("example-skew-after.jpg");
Category
Transformations
See also
Clear |
Crop |
Expand |
FlipHorizontal |
FlipVertical |
Opacity |
Resize |
Rotate |
RotateLeft |
RotateRight |
RoundEdges |
Shear |
Shrink |
Straighten |
Thumbnail