public class AsposeOCR extends Object
Constructor and Description |
---|
AsposeOCR()
Public constructor.
|
AsposeOCR(String alphabet)
Public constructor.
|
Modifier and Type | Method and Description |
---|---|
double |
CalcSkewImage(BufferedImage image)
Calculates the skew angle of the text in the image.
|
double |
CalcSkewImage(String fullPath)
Calculates the skew angle of the text in the image.
|
ArrayList<Rectangle> |
getTextAreas() |
String |
RecognizeLine(BufferedImage image_)
Recognizing a image that contains only one line of text.
|
String |
RecognizeLine(String fullPath)
Recognizing a image that contains only one line of text.
|
ArrayList<RecognitionResult> |
RecognizeMultiplePages(String path,
RecognitionSettings settings)
Batch text recognition in several images packed in ZIP archive or images from folder
Internal archives and folders are not supported
Only GIF, PNG, JPEG, BMP and WBMP internal images are used for recognition from ZIP archive or from folder
Only 20 GIF, PNG, JPEG, BMP, TIFF and WBMP images will be processed by text recognition
|
String |
RecognizePage(BufferedImage image)
Recognizing image with automatic detection of text areas
and detecting, correct skew of the text.
|
String |
RecognizePage(BufferedImage image_,
ArrayList<Rectangle> boxes_)
Recognizing text in a specified rectangles.
|
String |
RecognizePage(BufferedImage image,
boolean autoSkew)
Recognizing image with automatic detection of text areas.
|
RecognitionResult |
RecognizePage(BufferedImage image_,
RecognitionSettings settings)
Recognizing text in the specified options.
|
String |
RecognizePage(BufferedImage image_,
Rectangle box)
Will be deprecated
Recognizing text in a specified rectangle.
|
String |
RecognizePage(String fullPath)
Recognizing image with automatic detection of text areas
and detecting, correct skew of the text.
|
String |
RecognizePage(String fullPath,
ArrayList<Rectangle> boxes_)
Recognizing text in a specified rectangles.
|
String |
RecognizePage(String fullPath,
boolean autoSkew)
Recognizing image with automatic detection of text areas.
|
RecognitionResult |
RecognizePage(String fullPath,
RecognitionSettings settings)
Recognizing text from file in the specified options.
|
String |
RecognizePage(String fullPath,
Rectangle box)
Will be deprecated
Recognizing text in a specified rectangle.
|
RecognitionResult |
RecognizePageFromUri(String uri,
RecognitionSettings settings)
Recognizing text in a specified settings.
|
public AsposeOCR()
AsposeOCR(String)
public AsposeOCR(String alphabet)
alphabet
- Narrow alphabet for recognition.AsposeOCR()
public double CalcSkewImage(String fullPath) throws IOException
fullPath
- Path to image.IOException
- if file not found.public double CalcSkewImage(BufferedImage image) throws IOException
image
- BufferedImage instance.IOException
- if file not found.public ArrayList<Rectangle> getTextAreas()
public String RecognizePage(String fullPath) throws IOException
fullPath
- Path to image.IOException
- if file not found.public String RecognizePage(String fullPath, boolean autoSkew) throws IOException
fullPath
- Path to image.autoSkew
- Auto-skew text.IOException
- if file not found.public String RecognizePage(BufferedImage image) throws IOException
image
- Source BufferedImage.IOException
- if file not found.public String RecognizePage(BufferedImage image, boolean autoSkew) throws IOException
image
- BufferedImage instance.autoSkew
- Auto-skew text.IOException
- if file not found.public String RecognizePage(String fullPath, ArrayList<Rectangle> boxes_) throws IOException
fullPath
- Path to image.boxes_
- List of rectangles.IOException
- if file not found.public String RecognizePage(BufferedImage image_, ArrayList<Rectangle> boxes_) throws IOException
image_
- BufferedImage instance.boxes_
- List of rectangle.IOException
- if file not found.public String RecognizePage(String fullPath, Rectangle box) throws IOException
fullPath
- Path to image.box
- Rectangle for recognize.IOException
- if file not found.public String RecognizePage(BufferedImage image_, Rectangle box) throws IOException
image_
- BufferedImage instance.box
- Rectangle for recognize.IOException
- if file not found.public RecognitionResult RecognizePage(String fullPath, RecognitionSettings settings) throws IOException
fullPath
- Path to image.settings
- RecognizeSettings includes specified rectangles, skew angle and boolean values detectAreas, autoSkew, recognizeAsOneLine.IOException
- if file not found.public RecognitionResult RecognizePage(BufferedImage image_, RecognitionSettings settings) throws IOException
image_
- BufferedImage instance.settings
- RecognizeSettings includes specified rectangles, skew angle and boolean values detectAreas, autoSkew, recognizeAsOneLine.IOException
- if file not found.public ArrayList<RecognitionResult> RecognizeMultiplePages(String path, RecognitionSettings settings) throws IOException
path
- full path to the zip archive (with .zip name) or to the folder with imagessettings
- parameters for recognition
Allows to set automatic detection of text areas
Allows to set automatic skew correction of the text
Allows to set customer skew correction of the text
Allows to set rectangles in pixels for recognize.
Support language choose optionIOException
- if file not found.public RecognitionResult RecognizePageFromUri(String uri, RecognitionSettings settings) throws IOException
uri
- String link.settings
- RecognizeSettings includes specified rectangles and boolean values detectAreas, autoSkew, recognizeAsOneLine.IOException
- if file not found.public String RecognizeLine(String fullPath) throws IOException
fullPath
- Path to image.IOException
- if file not found.public String RecognizeLine(BufferedImage image_) throws IOException
image_
- BufferedImage instance.IOException
- if file not found.Copyright © 2020 Aspose. All rights reserved.