#include <blobbox.h>
|
| | TO_ROW () |
| |
| | TO_ROW (BLOBNBOX *blob, float top, float bottom, float row_size) |
| |
| float | max_y () const |
| |
| float | min_y () const |
| |
| float | mean_y () const |
| |
| float | initial_min_y () const |
| |
| float | line_m () const |
| |
| float | line_c () const |
| |
| float | line_error () const |
| |
| float | parallel_c () const |
| |
| float | parallel_error () const |
| |
| float | believability () const |
| |
| float | intercept () const |
| |
| void | add_blob (BLOBNBOX *blob, float top, float bottom, float row_size) |
| |
| void | insert_blob (BLOBNBOX *blob) |
| |
| BLOBNBOX_LIST * | blob_list () |
| |
| void | set_line (float new_m, float new_c, float new_error) |
| |
| void | set_parallel_line (float gradient, float new_c, float new_error) |
| |
| void | set_limits (float new_min, float new_max) |
| |
| void | compute_vertical_projection () |
| |
| bool | rep_chars_marked () const |
| |
| void | clear_rep_chars_marked () |
| |
| int | num_repeated_sets () const |
| |
| void | set_num_repeated_sets (int num_sets) |
| |
| | ELIST2_LINK () |
| |
| | ELIST2_LINK (const ELIST2_LINK &) |
| |
| void | operator= (const ELIST2_LINK &) |
| |
Definition at line 516 of file blobbox.h.
| TO_ROW::TO_ROW |
( |
BLOBNBOX * |
blob, |
|
|
float |
top, |
|
|
float |
bottom, |
|
|
float |
row_size |
|
) |
| |
Definition at line 638 of file blobbox.cpp.
647 initial_y_min = bottom;
650 BLOBNBOX_IT it = &blobs;
652 it.add_to_end (blob);
653 diff = top - bottom - row_size;
659 else if ((top - bottom) * 3 < row_size) {
660 diff = row_size / 3 + bottom - top;
| void TO_ROW::add_blob |
( |
BLOBNBOX * |
blob, |
|
|
float |
top, |
|
|
float |
bottom, |
|
|
float |
row_size |
|
) |
| |
Definition at line 673 of file blobbox.cpp.
681 BLOBNBOX_IT it = &blobs;
683 it.add_to_end (blob);
684 allowed = row_size + y_min - y_max;
686 available = top > y_max ? top - y_max : 0;
689 available += y_min - bottom;
691 available += available;
692 if (available < allowed)
695 y_min -= (y_min - bottom) * allowed / available;
697 y_max += (top - y_max) * allowed / available;
| float TO_ROW::believability |
( |
| ) |
const |
|
inline |
| BLOBNBOX_LIST* TO_ROW::blob_list |
( |
| ) |
|
|
inline |
| void TO_ROW::clear_rep_chars_marked |
( |
| ) |
|
|
inline |
Definition at line 606 of file blobbox.h.
607 num_repeated_sets_ = -1;
| void TO_ROW::compute_vertical_projection |
( |
| ) |
|
Definition at line 736 of file blobbox.cpp.
742 if (blob_it.empty ())
744 row_box = blob_it.data ()->bounding_box ();
745 for (blob_it.mark_cycle_pt (); !blob_it.cycled_list (); blob_it.forward ())
746 row_box += blob_it.data ()->bounding_box ();
752 for (blob_it.mark_cycle_pt (); !blob_it.cycled_list (); blob_it.forward ()) {
753 blob = blob_it.data();
void vertical_cblob_projection(C_BLOB *blob, STATS *stats)
bool set_range(inT32 min_bucket_value, inT32 max_bucket_value_plus_1)
#define PROJECTION_MARGIN
BLOBNBOX_LIST * blob_list()
| float TO_ROW::initial_min_y |
( |
| ) |
const |
|
inline |
Definition at line 539 of file blobbox.h.
540 return initial_y_min;
| void TO_ROW::insert_blob |
( |
BLOBNBOX * |
blob | ) |
|
Definition at line 709 of file blobbox.cpp.
712 BLOBNBOX_IT it = &blobs;
715 it.add_before_then_move (blob);
718 while (!it.cycled_list ()
719 && it.data ()->bounding_box ().left () <=
722 if (it.cycled_list ())
723 it.add_to_end (blob);
725 it.add_before_stay_put (blob);
const TBOX & bounding_box() const
| float TO_ROW::intercept |
( |
| ) |
const |
|
inline |
| float TO_ROW::line_c |
( |
| ) |
const |
|
inline |
| float TO_ROW::line_error |
( |
| ) |
const |
|
inline |
| float TO_ROW::line_m |
( |
| ) |
const |
|
inline |
| float TO_ROW::max_y |
( |
| ) |
const |
|
inline |
| float TO_ROW::mean_y |
( |
| ) |
const |
|
inline |
Definition at line 536 of file blobbox.h.
537 return (y_min + y_max) / 2.0f;
| float TO_ROW::min_y |
( |
| ) |
const |
|
inline |
| int TO_ROW::num_repeated_sets |
( |
| ) |
const |
|
inline |
Definition at line 609 of file blobbox.h.
610 return num_repeated_sets_;
| float TO_ROW::parallel_c |
( |
| ) |
const |
|
inline |
| float TO_ROW::parallel_error |
( |
| ) |
const |
|
inline |
| bool TO_ROW::rep_chars_marked |
( |
| ) |
const |
|
inline |
Definition at line 603 of file blobbox.h.
604 return num_repeated_sets_ != -1;
| void TO_ROW::set_limits |
( |
float |
new_min, |
|
|
float |
new_max |
|
) |
| |
|
inline |
| void TO_ROW::set_line |
( |
float |
new_m, |
|
|
float |
new_c, |
|
|
float |
new_error |
|
) |
| |
|
inline |
| void TO_ROW::set_num_repeated_sets |
( |
int |
num_sets | ) |
|
|
inline |
Definition at line 612 of file blobbox.h.
613 num_repeated_sets_ = num_sets;
| void TO_ROW::set_parallel_line |
( |
float |
gradient, |
|
|
float |
new_c, |
|
|
float |
new_error |
|
) |
| |
|
inline |
Definition at line 583 of file blobbox.h.
588 para_error = new_error;
591 y_origin = (float) (new_c / sqrt (1 + gradient * gradient));
static const int kErrorWeight
| ICOORDELT_LIST TO_ROW::char_cells |
| float TO_ROW::fixed_pitch |
| const int TO_ROW::kErrorWeight = 3 |
|
static |
| inT32 TO_ROW::max_nonspace |
| inT16 TO_ROW::projection_left |
| inT16 TO_ROW::projection_right |
| WERD_LIST TO_ROW::rep_words |
| inT32 TO_ROW::space_threshold |
| BOOL8 TO_ROW::used_dm_model |
| int TO_ROW::xheight_evidence |
The documentation for this class was generated from the following files:
- /home/abuild/rpmbuild/BUILD/tesseract-ocr-3.02.02/ccstruct/blobbox.h
- /home/abuild/rpmbuild/BUILD/tesseract-ocr-3.02.02/ccstruct/blobbox.cpp