VintaSoft Twain .NET SDK 15.4: Documentation for .NET developer
Vintasoft.WpfTwain Namespace / AcquiredImage Class / Crop(Int32,Int32,Int32,Int32) Method
Syntax Exceptions Example Requirements SeeAlso
In This Topic
Crop(Int32,Int32,Int32,Int32) Method (AcquiredImage)
In This Topic
Crops specified region of an image.
Syntax
'Declaration

Public Function Crop( _
ByVal x
The x-coordinate of the upper-left corner of the crop rectangle.
As Integer, _
ByVal y
The y-coordinate of the upper-left corner of the crop rectangle.
As Integer, _
ByVal width
The width of the crop rectangle.
As Integer, _
ByVal height
The height of the crop rectangle.
As Integer _
) As Boolean
public bool Crop(
int x,
int y,
int width,
int height
)

Parameters

x
The x-coordinate of the upper-left corner of the crop rectangle.
y
The y-coordinate of the upper-left corner of the crop rectangle.
width
The width of the crop rectangle.
height
The height of the crop rectangle.

Return Value

true if image is cropped; false if image is not cropped.
Exceptions
ExceptionDescription
Thrown if cropRect is not correct.
Example

Please see example here: AcquiredImage.

Requirements

Target Platforms: .NET 10; .NET 9; .NET 8; .NET 7; .NET 6; .NET Framework 4.8, 4.7, 4.6, 4.5, 4.0, 3.5

See Also