Click or drag to resize

AutoDeskewCommand Class

The AutoDeskewCommand automatically deskews a binary image using %%company%%'s patent pending auto-deskew algorithm.
Inheritance Hierarchy
SystemObject
  Atalasoft.Imaging.ImageProcessingImageCommand
    Atalasoft.Imaging.ImageProcessing.DocumentAutoDeskewCommand

Namespace:  Atalasoft.Imaging.ImageProcessing.Document
Assembly:  Atalasoft.dotImage (in Atalasoft.dotImage.dll) Version: 11.4.0.9.0.377 (.NET 4.5.2, x86)
Syntax
[SerializableAttribute]
public class AutoDeskewCommand : ImageCommand, 
	ISerializable

The AutoDeskewCommand type exposes the following members.

Constructors
  NameDescription
Public methodAutoDeskewCommand
Creates a new instance of AutoDeskewCommand.
Public methodAutoDeskewCommand(Rectangle)
Initializes a new instance of the AutoDeskewCommand with default settings and a rectangular area to process.
Public methodAutoDeskewCommand(Int32, Int32)
Initializes a new instance of the AutoDeskewCommand specifying the precision and limit angle.
Protected methodAutoDeskewCommand(SerializationInfo, StreamingContext)
Creates a new instance of AutoDeskewCommand from serialization information.
Public methodAutoDeskewCommand(Int32, Int32, Rectangle)
Initializes a new instance of the AutoDeskewCommand specifying the precision, limit angle, and rectangular area to process.
Public methodAutoDeskewCommand(Int32, Int32, AutoDeskewCropMode, Color, Rectangle)
Initializes a new instance of the AutoDeskewCommand specifying the precision, limit angle, crop mode, background color, and rectangular area to process.
Top
Properties
  NameDescription
Public propertyApplyToAnyPixelFormat
Reports whether or not this command will be applied to any supplied PixelFormat image
(Inherited from ImageCommand.)
Public propertyArea
Gets or sets rectangular area that will be used for determining the skew angle.
Public propertyBackgroundColor
Gets or sets the background color to use when de-skewing the image.
Public propertyCanApplyToAnyPixelFormat
Returns true if the command can be applied to any PixelFormat.
(Inherited from ImageCommand.)
Public propertyCoverage
Represents the percentage of the image that will be randomly sampled when determining the skew angle.
Public propertyCropMode
Gets or sets a value indicating the method of cropping the resulting de-skewed image.
Public propertyExtractBoundary
Gets or sets a value which will pre-process the image by removing solid filled areas of the image.
Public propertyInPlaceProcessing
Gets a value indicating if the source image data is processed in-place as opposed to returning a new image.
(Inherited from ImageCommand.)
Public propertyLimitAngle
Gets or sets the maximum skew angle in degrees.
Public propertyPrecision
Gets or sets the precision of the de-skew angle calculation.
Public propertyProgress
Gets or sets the ProgressEventHandler delegate which can be used to view or cancel the progress of the current process.
(Inherited from ImageCommand.)
Public propertySkewAngle Obsolete.
Gets a value indicating the last detected skew angle.
Public propertySupportedPixelFormats
Returns an array of PixelFormats supported by this command.
(Overrides ImageCommandSupportedPixelFormats.)
Top
Methods
  NameDescription
Public methodApply
Apply the command to the given image.
(Inherited from ImageCommand.)
Public methodApplyToImage Obsolete.
Applies the command to the source AtalaImage.
(Inherited from ImageCommand.)
Protected methodConstructChangedSourceImage
The method is called by the default implementation of Apply. It determines if it is necessary to create a copy of the source image in a different pixel format and if so, determines the best new pixel format and allocates that image.
(Inherited from ImageCommand.)
Protected methodConstructFinalImage
Represents the base class for all image processing routines that modify image data.
(Overrides ImageCommandConstructFinalImage(AtalaImage).)
Protected methodConstructImageResults
Represents the base class for all image processing routines that modify image data.
(Overrides ImageCommandConstructImageResults.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Protected methodGetChangedPixelFormat
This method is called to change the pixel format of the source image.
(Inherited from ImageCommand.)
Public methodGetDeskewAngle
GetDeskewAngle returns the skew angle of the image without changing the image at all.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetObjectData
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodImageCommandGetObjectData
Aggregates ImageCommand data into the supplied SerializationInfo object.
(Inherited from ImageCommand.)
Public methodIsPixelFormatSupported
Represents the base class for all image processing routines that modify image data.
(Overrides ImageCommandIsPixelFormatSupported(PixelFormat).)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Protected methodPerformActualCommand
Represents the base class for all image processing routines that modify image data.
(Overrides ImageCommandPerformActualCommand(AtalaImage, AtalaImage, Rectangle, ImageResults).)
Protected methodSelectBestAlternatePixelFormat
Choose the best pixel format to use for this command when the supplied source image's pixel format is unacceptable.
(Inherited from ImageCommand.)
Protected methodSelectPreferredPixelFormat
Chooses a pixel format that is preferred for this command.
(Inherited from ImageCommand.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Protected methodVerifyImage
Verify the integrity of an AtalaImage.
(Inherited from ImageCommand.)
Protected methodVerifyProperties
Represents the base class for all image processing routines that modify image data.
(Overrides ImageCommandVerifyProperties(AtalaImage).)
Top
Remarks

This command works best with images containing horizontal text.

There are a few ways to improve performance. Decrease the LimitAngle and Precision or pass in a smaller rectangular area containing the horizontally aligned text area. The Coverage property can be decreased to increase performance, however it will result in loss accuracy. For guaranteed accuracy, set the Coverage property to 100.

The SkewAngle property is set to the last detected skew angle. See GetDeskewAngle(AtalaImage) to determine the skew angle without actually rotating the image.

As of 6.0 AutoDeskewCommnd now additionally supports the following image formats: ,Pixel8bppGrayscale, Pixel24bppBgr, Pixel32bppBgr and Pixel32bppBgra.

See Also