Class RecognitionSettings

Class RecognitionSettings

Namespace: Aspose.OCR
Assembly: Aspose.OCR.dll (25.8.0)

Settings for the image recognition. Contains elements that allow customizing the recognition process.

public class RecognitionSettings : BaseRecognitionSettings

Inheritance

object BaseRecognitionSettings RecognitionSettings

Inherited Members

BaseRecognitionSettings.ThreadsCount , BaseRecognitionSettings.Language , BaseRecognitionSettings.IgnoredSymbols , BaseRecognitionSettings.AllowedSymbols , BaseRecognitionSettings.AllowedCharacters , BaseRecognitionSettings.AutomaticColorInversion , object.GetType() , object.MemberwiseClone() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()

Constructors

RecognitionSettings()

Initializes a new instance of the Aspose.OCR.RecognitionSettings class with auto skew = true.

public RecognitionSettings()

RecognitionSettings(Language, List<rectangle>, bool)

Initializes a new instance of the Aspose.OCR.RecognitionSettings class with full set of properties.

public RecognitionSettings(Language language = Language.Latin, List<rectangle> recognitionAreas = null, bool recognizeSingleLine = false)

Parameters

language Language

Language used for OCR.

recognitionAreas List <rectangle>

Manually set areas for recognition. Null by default - means whole image is processed.

recognizeSingleLine bool

For single-line images

Properties

DetectAreasMode

Allows to select the optimal mode for document type areas: document, photo, plain text, column, image.

public DetectAreasMode DetectAreasMode { get; set; }

Property Value

DetectAreasMode

LanguageDetectionLevel

Specifies the level of language detection for text recognition. Works only if the selected language is Aspose.OCR.Language.Multilanguage, Aspose.OCR.Language.Auto, or Aspose.OCR.Language.Universal. This process is time-consuming and significantly slows down the overall recognition.

public LanguageDetectionLevel LanguageDetectionLevel { get; set; }

Property Value

LanguageDetectionLevel

LinesFiltration

Allows to recognize text in the tables (regions surrounded lines).

public bool LinesFiltration { get; set; }

Property Value

bool

RecognitionAreas

Gets or sets the list of text areas for processing. Allows to manually specify the areas with text for more accurate recognition. Disables AutoSkew.

public List<rectangle> RecognitionAreas { get; set; }

Property Value

List <rectangle>

RecognizeSingleLine

Sets single-line image recognition. Disabled (false) by default. Disable all the processing steps associated with splitting into lines. Set this parameter to true if your image contains only one line. Disables RecognitionAreas settings, so all areas settings will be ignored.

public bool RecognizeSingleLine { get; set; }

Property Value

bool

UpscaleSmallFont

Allows you to use additional algorithms specifically for small font recognition. Useful for images with small size characters.

public bool UpscaleSmallFont { get; set; }

Property Value

bool </rectangle></rectangle></rectangle>

 English