PDFix SDK  6.20.0
Loading...
Searching...
No Matches
TesseractDoc Struct Referenceabstract

TesseractDoc class. More...

#include <ocr_tesseract.h>

Public Member Functions

virtual bool Close ()=0
 Closes TesseractDoc. More...
 
virtual bool OcrImageToPage (PsImage *image, PdfMatrix *matrix, PdfPage *page, PdfCancelProc cancel_proc, void *cancel_data)=0
 Recognize text on the page and add recognized text on the page. More...
 

Detailed Description

TesseractDoc class.

A TesseractDoc allow you to convert image based PDF to searchable document.

Member Function Documentation

◆ Close()

virtual bool TesseractDoc::Close ( )
pure virtual

◆ OcrImageToPage()

virtual bool TesseractDoc::OcrImageToPage ( PsImage image,
PdfMatrix matrix,
PdfPage page,
PdfCancelProc  cancel_proc,
void *  cancel_data 
)
pure virtual

Recognize text on the page and add recognized text on the page.

Parameters
paramsOcrTesseractParams that allows modify the OCR algorithm.
pageThe page to be processed
cancel_procCallback to check for canceling operations.
cancel_dataPointer to client data for the cancel procedure.
Returns
true if the searchable document was created successfully or false in case of an error. Process OCR on an image and insert recognized text onto the page.
Parameters
imageThe image to be processed.
matrixTransformation matrix to be applied on the text added to page.
pageThe destination page where the text will be added.
cancel_procCallback to check for canceling operations.
cancel_dataPointer to client data for the cancel procedure.
Returns
true if the image was processed successfully and text was added to the page or false in case of an error.