WERD Class Reference
#include <werd.h>
List of all members.
Constructor & Destructor Documentation
WERD::WERD |
( |
C_BLOB_LIST * |
blob_list, |
|
|
uinT8 |
blank_count, |
|
|
const char * |
text | |
|
) |
| | |
WERD::WERD
Constructor to build a WERD from a list of C_BLOBs. blob_list The C_BLOBs (in word order) are not copied; we take its elements and put them in our lists. blank_count blanks in front of the word text correct text, outlives this WERD
WERD::WERD |
( |
C_BLOB_LIST * |
blob_list, |
|
|
WERD * |
clone | |
|
) |
| | |
WERD::WERD
Constructor to build a WERD from a list of C_BLOBs. The C_BLOBs are not copied so the source list is emptied.
Member Function Documentation
TBOX WERD::bounding_box |
( |
|
) |
|
WERD::bounding_box
Return the bounding box of the WERD. This is quite a mess to compute! ORIGINALLY, REJECT CBLOBS WERE EXCLUDED, however, this led to bugs when the words on the row were re-sorted. The original words were built with reject blobs included. The FUZZY SPACE flags were set accordingly. If ALL the blobs in a word are rejected the BB for the word is NULL, causing the sort to screw up, leading to the erroneous possibility of the first word in a row being marked as FUZZY space.
C_BLOB_LIST* WERD::cblob_list |
( |
|
) |
[inline] |
WERD * WERD::ConstructFromSingleBlob |
( |
bool |
bol, |
|
|
bool |
eol, |
|
|
C_BLOB * |
blob | |
|
) |
| | |
WERD * WERD::ConstructWerdWithNewBlobs |
( |
C_BLOB_LIST * |
all_blobs, |
|
|
C_BLOB_LIST * |
orphan_blobs | |
|
) |
| | |
WERD::ConstructWerdWithNewBlobs()
This method returns a new werd constructed using the blobs in the input all_blobs list, which correspond to the blobs in this werd object. The blobs used to construct the new word are consumed and removed from the input all_blobs list. Returns NULL if the word couldn't be constructed. Returns original blobs for which no matches were found in the output list orphan_blobs (appends).
void WERD::copy_on |
( |
WERD * |
other |
) |
|
BOOL8 WERD::display_flag |
( |
uinT8 |
flag |
) |
const [inline] |
void WERD::join_on |
( |
WERD * |
other |
) |
|
WERD::join_on
Join other word onto this one. Delete the old word.
void WERD::move |
( |
const ICOORD |
vec |
) |
|
WERD::move
Reposition WERD by vector NOTE!! REJECT CBLOBS ARE NOT MOVED
WERD & WERD::operator= |
( |
const WERD & |
source |
) |
|
C_BLOB_LIST* WERD::rej_cblob_list |
( |
|
) |
[inline] |
int WERD::script_id |
( |
|
) |
const [inline] |
void WERD::set_blanks |
( |
uinT8 |
new_blanks |
) |
[inline] |
void WERD::set_display_flag |
( |
uinT8 |
flag, |
|
|
BOOL8 |
value | |
|
) |
| | [inline] |
void WERD::set_script_id |
( |
int |
id |
) |
[inline] |
void WERD::set_text |
( |
const char * |
new_text |
) |
[inline] |
WERD * WERD::shallow_copy |
( |
|
) |
|
uinT8 WERD::space |
( |
|
) |
[inline] |
const char* WERD::text |
( |
|
) |
const [inline] |
The documentation for this class was generated from the following files:
- /home/rays/src/opensrc/tesseract-ocr/ccstruct/werd.h
- /home/rays/src/opensrc/tesseract-ocr/ccstruct/werd.cpp