IDCardRecognitionSettings
Inheritance: java.lang.Object, com.aspose.ocr.ReceiptRecognitionSettings
public class IDCardRecognitionSettings extends ReceiptRecognitionSettings
Settings for the ID Card recognition Contains elements that allow customizing the recognition process
Constructors
Constructor | Description |
---|---|
IDCardRecognitionSettings() | Default constructor: set autoSkew true. |
Methods
Method | Description |
---|---|
setAllowedCharacters(CharactersAllowedType allowedCharacters) | Allowed characters set. |
setAllowedCharacters(String allowedCharacters) | Allowed characters set. |
setAutomaticColorInversion(boolean automaticColorInversion) | Detect images with white text on dark/black background and automatically choose a special OCR algorithm for them. |
setIgnoredCharacters(String characters) | Sets blacklist for recognition symbols. |
setLanguage(Language language) | |
setThreadsCount(int threadsCount) | Gets or sets the number of threads for processing. |
setUpscaleSmallFont(boolean upscaleSmallFont) | Allows you to use additional algorithms specifically for small font recognition. |
IDCardRecognitionSettings()
public IDCardRecognitionSettings()
Default constructor: set autoSkew true.
setAllowedCharacters(CharactersAllowedType allowedCharacters)
public void setAllowedCharacters(CharactersAllowedType allowedCharacters)
Allowed characters set. Determines the type of characters allowed for recognition result.
Parameters:
Parameter | Type | Description |
---|---|---|
allowedCharacters | CharactersAllowedType | contains enum @see CharactersAllowedType value. |
setAllowedCharacters(String allowedCharacters)
public void setAllowedCharacters(String allowedCharacters)
Allowed characters set. Determines the array of characters allowed for recognition result.
Parameters:
Parameter | Type | Description |
---|---|---|
allowedCharacters | java.lang.String | contains array of characters. |
setAutomaticColorInversion(boolean automaticColorInversion)
public void setAutomaticColorInversion(boolean automaticColorInversion)
Detect images with white text on dark/black background and automatically choose a special OCR algorithm for them.
Parameters:
Parameter | Type | Description |
---|---|---|
automaticColorInversion | boolean | contains boolean value - a automaticColorInversion is set. |
setIgnoredCharacters(String characters)
public void setIgnoredCharacters(String characters)
Sets blacklist for recognition symbols.
Parameters:
Parameter | Type | Description |
---|---|---|
characters | java.lang.String | Characters excluded from recognition. |
setLanguage(Language language)
public void setLanguage(Language language)
Parameters:
Parameter | Type | Description |
---|---|---|
language | Language | Sets the language used for OCR. Multi-language (none) by default. |
setThreadsCount(int threadsCount)
public void setThreadsCount(int threadsCount)
Gets or sets the number of threads for processing. By default, 0 means that the image will be processed with the number of threads equal to your number of processors. ThreadsCount = 1 means that the image will be processed in the main thread.
Parameters:
Parameter | Type | Description |
---|---|---|
threadsCount | int | the number of threads that will be created for parallel recognition of image fragments. |
setUpscaleSmallFont(boolean upscaleSmallFont)
public void setUpscaleSmallFont(boolean upscaleSmallFont)
Allows you to use additional algorithms specifically for small font recognition. Useful for images with small size characters.
Parameters:
Parameter | Type | Description |
---|---|---|
upscaleSmallFont | boolean | contains boolean value - a upscaleSmallFont is set. |