Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old

Component: OCR

Recognize text on images.

See also WindowsOCR functions for Windows and Vision functions for macOS.

Version macOS Windows Linux Server iOS SDK
2.9 / 13.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes

Item Details
OCR.Cleanup
Shutdown the engine and free all memory.
All
2.9
OCR.Clear
Free up recognition results and any stored image data, without actually freeing any recognition data that would be time-consuming to reload.
All
2.9
OCR.GetBoxText
The recognized text is returned as a text which is coded in the same format as a box file used in training.
All
2.9
OCR.GetHOCRText
Make a HTML-formatted string with hOCR markup from the internal data structures.
All
2.9
OCR.GetPageSegMode
Queries page segmentation mode.
All
2.9
OCR.GetText
Returns recognized text.
All
2.9
OCR.GetTextAsJSON
Queries result as JSON.
All
13.3
OCR.GetTextWithCoordinates
Queries text with coordinates.
All
6.5
OCR.GetVariable
Queries a variable.
All
7.5
OCR.Initialize
Initializes tesseract.
All
2.9
OCR.IsInitialized
Checks if OCR library has been initialized.
All
4.2
OCR.IsLoaded
Whether newer tesseract is loaded.
All
11.3
OCR.Language
Return the language used in the last valid initialization.
All
2.9
OCR.Load
Loads newer tesseract engine.
All
11.3
OCR.MeanTextConf
Returns the (average) confidence value between 0 and 100.
All
2.9
OCR.Recognize
Recognize the image.
All
2.9
OCR.SetImage
Provide an image for Tesseract to recognize.
All
2.9
OCR.SetImageContainer
Loads a picture from container.
All
11.3
OCR.SetImageFile
Loads a picture from file directly.
All
11.3
OCR.SetPageSegMode
Sets page segmentation mode.
All
2.9
OCR.SetRectangle
Restrict recognition to a sub-rectangle of the image.
All
2.9
OCR.SetResolution
Set the resolution of the source image in pixels per inch.
All
5.1
OCR.SetVariable
Sets a variable.
All
7.5
OCR.Version
Query version of Tesseract library.
All
11.3
OCR.WriteToPDF
Writes text on the PDF.
All
3.1

25 functions shown.

Release notes

Blog Entries

Example Databases