tesseract  v4.0.0-17-g361f3264
Open Source OCR Engine
tesseract::ShiroRekhaSplitter Class Reference

#include <devanagari_processing.h>

Public Types

enum  SplitStrategy { NO_SPLIT = 0, MINIMAL_SPLIT, MAXIMAL_SPLIT }
 

Public Member Functions

 ShiroRekhaSplitter ()
 
virtual ~ShiroRekhaSplitter ()
 
bool Split (bool split_for_pageseg, DebugPixa *pixa_debug)
 
void Clear ()
 
void RefreshSegmentationWithNewBlobs (C_BLOB_LIST *new_blobs)
 
bool HasDifferentSplitStrategies () const
 
void set_segmentation_block_list (BLOCK_LIST *block_list)
 
void set_global_xheight (int xheight)
 
void set_perform_close (bool perform)
 
Pix * splitted_image ()
 
void set_orig_pix (Pix *pix)
 
Pix * orig_pix ()
 
SplitStrategy ocr_split_strategy () const
 
void set_ocr_split_strategy (SplitStrategy strategy)
 
SplitStrategy pageseg_split_strategy () const
 
void set_pageseg_split_strategy (SplitStrategy strategy)
 
BLOCK_LIST * segmentation_block_list ()
 

Static Public Member Functions

static int GetModeHeight (Pix *pix)
 

Static Public Attributes

static const int kUnspecifiedXheight = -1
 

Private Member Functions

int GetXheightForCC (Box *cc_bbox)
 
void SplitWordShiroRekha (SplitStrategy split_strategy, Pix *pix, int xheight, int word_left, int word_top, Boxa *regions_to_clear)
 
Box * GetBoxForTBOX (const TBOX &tbox) const
 

Static Private Member Functions

static void PerformClose (Pix *pix, int xheight_estimate)
 
static void GetShiroRekhaYExtents (Pix *word_pix, int *shirorekha_top, int *shirorekha_bottom, int *shirorekha_ylevel)
 

Private Attributes

Pix * orig_pix_
 
Pix * splitted_image_
 
SplitStrategy pageseg_split_strategy_
 
SplitStrategy ocr_split_strategy_
 
Pix * debug_image_
 
BLOCK_LIST * segmentation_block_list_
 
int global_xheight_
 
bool perform_close_
 

Member Enumeration Documentation

◆ SplitStrategy

Enumerator
NO_SPLIT 
MINIMAL_SPLIT 
MAXIMAL_SPLIT 

Constructor & Destructor Documentation

◆ ShiroRekhaSplitter()

tesseract::ShiroRekhaSplitter::ShiroRekhaSplitter ( )

◆ ~ShiroRekhaSplitter()

tesseract::ShiroRekhaSplitter::~ShiroRekhaSplitter ( )
virtual

Member Function Documentation

◆ Clear()

void tesseract::ShiroRekhaSplitter::Clear ( )

◆ GetBoxForTBOX()

Box * tesseract::ShiroRekhaSplitter::GetBoxForTBOX ( const TBOX tbox) const
private

◆ GetModeHeight()

int tesseract::ShiroRekhaSplitter::GetModeHeight ( Pix *  pix)
static

◆ GetShiroRekhaYExtents()

void tesseract::ShiroRekhaSplitter::GetShiroRekhaYExtents ( Pix *  word_pix,
int *  shirorekha_top,
int *  shirorekha_bottom,
int *  shirorekha_ylevel 
)
staticprivate

◆ GetXheightForCC()

int tesseract::ShiroRekhaSplitter::GetXheightForCC ( Box *  cc_bbox)
private

◆ HasDifferentSplitStrategies()

bool tesseract::ShiroRekhaSplitter::HasDifferentSplitStrategies ( ) const
inline

◆ ocr_split_strategy()

SplitStrategy tesseract::ShiroRekhaSplitter::ocr_split_strategy ( ) const
inline

◆ orig_pix()

Pix* tesseract::ShiroRekhaSplitter::orig_pix ( )
inline

◆ pageseg_split_strategy()

SplitStrategy tesseract::ShiroRekhaSplitter::pageseg_split_strategy ( ) const
inline

◆ PerformClose()

void tesseract::ShiroRekhaSplitter::PerformClose ( Pix *  pix,
int  xheight_estimate 
)
staticprivate

◆ RefreshSegmentationWithNewBlobs()

void tesseract::ShiroRekhaSplitter::RefreshSegmentationWithNewBlobs ( C_BLOB_LIST *  new_blobs)

◆ segmentation_block_list()

BLOCK_LIST* tesseract::ShiroRekhaSplitter::segmentation_block_list ( )
inline

◆ set_global_xheight()

void tesseract::ShiroRekhaSplitter::set_global_xheight ( int  xheight)
inline

◆ set_ocr_split_strategy()

void tesseract::ShiroRekhaSplitter::set_ocr_split_strategy ( SplitStrategy  strategy)
inline

◆ set_orig_pix()

void tesseract::ShiroRekhaSplitter::set_orig_pix ( Pix *  pix)

◆ set_pageseg_split_strategy()

void tesseract::ShiroRekhaSplitter::set_pageseg_split_strategy ( SplitStrategy  strategy)
inline

◆ set_perform_close()

void tesseract::ShiroRekhaSplitter::set_perform_close ( bool  perform)
inline

◆ set_segmentation_block_list()

void tesseract::ShiroRekhaSplitter::set_segmentation_block_list ( BLOCK_LIST *  block_list)
inline

◆ Split()

bool tesseract::ShiroRekhaSplitter::Split ( bool  split_for_pageseg,
DebugPixa pixa_debug 
)

◆ splitted_image()

Pix* tesseract::ShiroRekhaSplitter::splitted_image ( )
inline

◆ SplitWordShiroRekha()

void tesseract::ShiroRekhaSplitter::SplitWordShiroRekha ( SplitStrategy  split_strategy,
Pix *  pix,
int  xheight,
int  word_left,
int  word_top,
Boxa *  regions_to_clear 
)
private

Member Data Documentation

◆ debug_image_

Pix* tesseract::ShiroRekhaSplitter::debug_image_
private

◆ global_xheight_

int tesseract::ShiroRekhaSplitter::global_xheight_
private

◆ kUnspecifiedXheight

const int tesseract::ShiroRekhaSplitter::kUnspecifiedXheight = -1
static

◆ ocr_split_strategy_

SplitStrategy tesseract::ShiroRekhaSplitter::ocr_split_strategy_
private

◆ orig_pix_

Pix* tesseract::ShiroRekhaSplitter::orig_pix_
private

◆ pageseg_split_strategy_

SplitStrategy tesseract::ShiroRekhaSplitter::pageseg_split_strategy_
private

◆ perform_close_

bool tesseract::ShiroRekhaSplitter::perform_close_
private

◆ segmentation_block_list_

BLOCK_LIST* tesseract::ShiroRekhaSplitter::segmentation_block_list_
private

◆ splitted_image_

Pix* tesseract::ShiroRekhaSplitter::splitted_image_
private

The documentation for this class was generated from the following files: