tesseract  5.0.0-alpha-619-ge9db
tesseract::TessOsdRenderer Class Reference

#include <renderer.h>

Inheritance diagram for tesseract::TessOsdRenderer:
tesseract::TessResultRenderer

Public Member Functions

 TessOsdRenderer (const char *outputbase)
 
- Public Member Functions inherited from tesseract::TessResultRenderer
virtual ~TessResultRenderer ()
 
void insert (TessResultRenderer *next)
 
TessResultRenderernext ()
 
bool BeginDocument (const char *title)
 
bool AddImage (TessBaseAPI *api)
 
bool EndDocument ()
 
const char * file_extension () const
 
const char * title () const
 
bool happy ()
 
int imagenum () const
 

Protected Member Functions

bool AddImageHandler (TessBaseAPI *api) override
 
- Protected Member Functions inherited from tesseract::TessResultRenderer
 TessResultRenderer (const char *outputbase, const char *extension)
 
virtual bool BeginDocumentHandler ()
 
virtual bool EndDocumentHandler ()
 
void AppendString (const char *s)
 
void AppendData (const char *s, int len)
 

Detailed Description

Renders tesseract output into an osd text string

Definition at line 299 of file renderer.h.

Constructor & Destructor Documentation

◆ TessOsdRenderer()

tesseract::TessOsdRenderer::TessOsdRenderer ( const char *  outputbase)
explicit

Definition at line 206 of file renderer.cpp.

Member Function Documentation

◆ AddImageHandler()

bool tesseract::TessOsdRenderer::AddImageHandler ( TessBaseAPI api)
overrideprotectedvirtual

Implements tesseract::TessResultRenderer.

Definition at line 209 of file renderer.cpp.

213  : TessResultRenderer(outputbase, "osd") {}
214 
216  char* osd = api->GetOsdText(imagenum());
217  if (osd == nullptr) return false;

The documentation for this class was generated from the following files:
tesseract::TessOsdRenderer::AddImageHandler
bool AddImageHandler(TessBaseAPI *api) override
Definition: renderer.cpp:209
tesseract::TessResultRenderer::TessResultRenderer
TessResultRenderer(const char *outputbase, const char *extension)
Definition: renderer.cpp:32
tesseract::TessResultRenderer::imagenum
int imagenum() const
Definition: renderer.h:107
TessBaseAPI
struct TessBaseAPI TessBaseAPI
Definition: capi.h:72