CodeCarvings.Piczard
CalculateCropRectangle(Size,Single,CropConstraint) Method
See Also  Send Feedback
CodeCarvings.Piczard Namespace > ImageSelection Class > CalculateCropRectangle Method : CalculateCropRectangle(Size,Single,CropConstraint) Method

sourceImageSize
The Size of the source image expressed in pixels.
outputResolution
The output image resolution (DPI).
cropConstraint
An (optional) CropConstraint filter that defines the constraints to use to calculate the Rectangle.
Calculates the crop Rectangle (in case its value is null) according to the provided CropConstraint settings and using the specified resolution (DPI).

Syntax

Visual Basic (Declaration)  
Public Overloads Sub CalculateCropRectangle( _
   ByVal sourceImageSize As Size, _
   ByVal outputResolution As Single, _
   ByVal cropConstraint As CropConstraint _
) 
C#  
public void CalculateCropRectangle( 
   Size sourceImageSize,
   float outputResolution,
   CropConstraint cropConstraint
)

Parameters

sourceImageSize
The Size of the source image expressed in pixels.
outputResolution
The output image resolution (DPI).
cropConstraint
An (optional) CropConstraint filter that defines the constraints to use to calculate the Rectangle.

Remarks

If the value of the Crop.Rectangle property is null then this method changes its value.
If the value of the Crop.Rectangle property is not null then this method do nothing.

Requirements

Platforms: Windows 8, Windows 7, Windows Vista, Windows XP Professional, Windows 2000 - Windows Server family: 2012, 2008.R2, 2008, 2003, 2000

See Also

©2013 Sergio Turolla. All Rights Reserved.