Home
last modified time | relevance | path

Searched refs:blob_box (Results 1 – 25 of 31) sorted by relevance

12

/dports/graphics/tesseract/tesseract-5.0.0/src/textord/
H A Dtospace.cpp120 TBOX blob_box; in block_spacing_stats() local
151 prev_blob_box = blob_box; in block_spacing_stats()
281 TBOX blob_box; in row_spacing_stats() local
322 prev_blob_box = blob_box; in row_spacing_stats()
351 prev_blob_box = blob_box; in row_spacing_stats()
642 TBOX blob_box; in isolated_row_stats() local
674 prev_blob_box = blob_box; in isolated_row_stats()
701 prev_blob_box = blob_box; in isolated_row_stats()
1582 TBOX blob_box; in find_mean_blob_spacing() local
1723 TBOX blob_box; in reduced_box_for_blob() local
[all …]
H A Dtordmain.cpp501 blob_size = blob_box.width() > blob_box.height() ? blob_box.width() : blob_box.height(); in clean_noise_from_row()
517 blob_size = blob_box.width() > blob_box.height() ? blob_box.width() : blob_box.height(); in clean_noise_from_row()
531 blob_box.bottom(), blob_box.right(), blob_box.top(), blob->out_list()->length(), in clean_noise_from_row()
532 trans_count, blob_box.bottom() - row->base_line(blob_box.left())); in clean_noise_from_row()
537 tprintf("Row ending at (%d,%g):", blob_box.right(), row->base_line(blob_box.right())); in clean_noise_from_row()
597 blob_size = blob_box.width() > blob_box.height() ? blob_box.width() : blob_box.height(); in clean_noise_from_words()
613 blob_size = blob_box.width() > blob_box.height() ? blob_box.width() : blob_box.height(); in clean_noise_from_words()
795 blob_box.rotate(rotation); in TransferDiacriticsToWords()
796 ws.StartRectSearch(blob_box); in TransferDiacriticsToWords()
818 if (word_box.major_y_overlap(blob_box) && blob_box.left() > word_box.right()) { in TransferDiacriticsToWords()
[all …]
H A Dblkocc.cpp56 auto blob_box = blob->bounding_box(); in test_underline() local
58 projection.set_range(blob_box.bottom(), blob_box.top() + 1); in test_underline()
72 for (occ = blob_box.bottom(); occ < baseline; occ++) { in test_underline()
73 if (occ <= blob_box.top() && projection.pile_count(occ) > desc_occ) { in test_underline()
80 if (occ >= blob_box.bottom() && occ <= blob_box.top() && projection.pile_count(occ) > x_occ) { in test_underline()
86 for (occ = baseline + xheight + 1; occ <= blob_box.top(); occ++) { in test_underline()
87 if (occ >= blob_box.bottom() && projection.pile_count(occ) > asc_occ) { in test_underline()
95 tprintf("Bottom=%d, top=%d, base=%d, x=%d\n", blob_box.bottom(), blob_box.top(), baseline, in test_underline()
H A Dgap_map.cpp41 TBOX blob_box; in GAPMAP() local
97 blob_box = box_next(&blob_it); in GAPMAP()
98 prev_blob_box = blob_box; in GAPMAP()
101 gap_width = blob_box.left() - min_left; in GAPMAP()
103 max_quantum = (blob_box.left() - min_left) / bucket_size; in GAPMAP()
113 blob_box = box_next(&blob_it); in GAPMAP()
114 gap_width = blob_box.left() - prev_blob_box.right(); in GAPMAP()
117 max_quantum = (blob_box.left() - min_left) / bucket_size; in GAPMAP()
125 prev_blob_box = blob_box; in GAPMAP()
H A Dunderlin.cpp36 TBOX blob_box; // of underline in restore_underlined_blobs() local
54 blob_box = u_line->bounding_box(); in restore_underlined_blobs()
81 split_to_blob(nullptr, blob_box.right(), textord_fp_chop_error + 0.5, &left_coutlines, in restore_underlined_blobs()
166 TBOX blob_box = u_line->bounding_box(); in find_underlined_blobs() local
169 STATS upper_proj(blob_box.left(), blob_box.right() + 1); in find_underlined_blobs()
170 STATS middle_proj(blob_box.left(), blob_box.right() + 1); in find_underlined_blobs()
171 STATS lower_proj(blob_box.left(), blob_box.right() + 1); in find_underlined_blobs()
182 for (auto x = blob_box.left(); x < blob_box.right(); x++) { in find_underlined_blobs()
185 for (; y < blob_box.right() && middle_proj.pile_count(y) > 0; y++) { in find_underlined_blobs()
H A Dwordseg.cpp185 TBOX blob_box; // bounding box in row_words() local
200 blob_box = blob->bounding_box(); in row_words()
201 if (blob_box.contains(testpt)) { in row_words()
204 gap_stats.add(blob_box.width(), 1); in row_words()
210 blob_box = blob->bounding_box(); in row_words()
215 prev_x = blob_box.right(); in row_words()
341 TBOX blob_box; // bounding box in row_words2() local
363 blob_box = blob->bounding_box(); in row_words2()
369 prev_x = blob_box.right(); in row_words2()
380 blob_box = blob->bounding_box(); in row_words2()
[all …]
H A Ddrawtord.cpp248 TBOX blob_box; // bounding box in plot_word_decisions() local
258 blob_box = blob->bounding_box(); in plot_word_decisions()
259 if (!blob->joined_to_prev() && blob_box.left() - prev_x > row->max_nonspace) { in plot_word_decisions()
260 if ((blob_box.left() - prev_x >= row->min_space || in plot_word_decisions()
261 blob_box.left() - prev_x > row->space_threshold) && in plot_word_decisions()
276 if (blob_box.left() - prev_x < row->min_space) { in plot_word_decisions()
277 if (blob_box.left() - prev_x > row->space_threshold) { in plot_word_decisions()
284 win->Rectangle(prev_x, blob_box.bottom(), blob_box.left(), blob_box.top()); in plot_word_decisions()
288 prev_x = blob_box.right(); in plot_word_decisions()
H A Dtopitch.cpp660 TBOX blob_box; // bounding box in row_pitch_stats() local
681 prev_x = blob_box.right(); in row_pitch_stats()
1029 TBOX blob_box; // bounding box in count_pitch_stats() local
1045 blob_box = blob->bounding_box(); in count_pitch_stats()
1084 joined_box = blob_box; in count_pitch_stats()
1359 prev_box = blob_box; in compute_pitch_sd()
1361 blob_box = box_next(&blob_it); in compute_pitch_sd()
1487 blob_box = box_next(&blob_it); in compute_pitch_sd2()
1495 tprintf("Row ending at (%d,%d), len=%d, sync rating=%g, ", blob_box.right(), blob_box.top(), in compute_pitch_sd2()
1586 prev_box = blob_box; in print_pitch_sd()
[all …]
H A Dpitsync1.cpp355 TBOX blob_box, // bounding box in make_illegal_segment() argument
388 while (x > blob_box.right()) { in make_illegal_segment()
389 blob_box = box_next(&blob_it); in make_illegal_segment()
391 offset = x - blob_box.left(); in make_illegal_segment()
392 if (blob_box.right() - x < offset) { in make_illegal_segment()
393 offset = blob_box.right() - x; in make_illegal_segment()
H A Dmakerow.cpp770 TBOX blob_box; // of block in deskew_block_coords() local
787 result += blob_box; in deskew_block_coords()
831 int32_t width = blob_box.right() - blob_box.left(); in compute_line_occupation()
836 index = blob_box.top() - min_y; in compute_line_occupation()
1768 if (blob_box.height() >= min_height && box.major_overlap(blob_box)) { in CountOverlaps()
1789 TBOX blob_box; in separate_underlines() local
1824 blob_box.print(); in separate_underlines()
1832 blob_box.print(); in separate_underlines()
1857 TBOX blob_box; in pre_associate_blobs() local
1909 blob_box.rotate(rotation); in pre_associate_blobs()
[all …]
H A Dstrokewidth.cpp542 if (!blob_box.y_overlap(part_box)) { in MarkLeaderNeighbours()
563 leaders_win_->Rectangle(blob_box.left(), blob_box.bottom(), blob_box.right(), blob_box.top()); in MarkLeaderNeighbours()
895 TBOX blob_box = blob->bounding_box(); in FindGoodNeighbour() local
896 bool debug = AlignedBlob::WithinTestRegion(2, blob_box.left(), blob_box.bottom()); in FindGoodNeighbour()
899 blob_box.print(); in FindGoodNeighbour()
901 int top = blob_box.top(); in FindGoodNeighbour()
902 int bottom = blob_box.bottom(); in FindGoodNeighbour()
903 int left = blob_box.left(); in FindGoodNeighbour()
904 int right = blob_box.right(); in FindGoodNeighbour()
927 TBOX search_box = blob_box; in FindGoodNeighbour()
[all …]
H A Dtextord.h183 TBOX blob_box, // for next_blob // how many blanks?
188 bool narrow_blob(TO_ROW *row, TBOX blob_box);
189 bool wide_blob(TO_ROW *row, TBOX blob_box);
H A Dpitsync1.h96 TBOX blob_box, // bounding box
/dports/graphics/tesseract/tesseract-5.0.0/unittest/
H A Dtablefind_test.cc219 TBOX blob_box = part_box; in TEST_F() local
221 blob_box.set_left(i + 1); in TEST_F()
222 blob_box.set_right(i + 4); in TEST_F()
223 all->AddBox(new BLOBNBOX(C_BLOB::FakeBlob(blob_box))); in TEST_F()
226 blob_box.set_left(i + 1); in TEST_F()
227 blob_box.set_right(i + 4); in TEST_F()
231 blob_box.set_left(i + 1); in TEST_F()
232 blob_box.set_right(i + 4); in TEST_F()
259 TBOX blob_box = part_box; in TEST_F() local
261 blob_box.set_left(i + 1); in TEST_F()
[all …]
/dports/graphics/tesseract/tesseract-5.0.0/src/ccstruct/
H A Dboxword.cpp65 TBOX blob_box; in CopyFromNormalized() local
78 blob_box += pt_box; in CopyFromNormalized()
83 boxword->boxes_.push_back(blob_box); in CopyFromNormalized()
102 TBOX blob_box = b_it.data()->bounding_box(); in ClipToOriginalWord() local
104 blob_box.rotate(block->re_rotation()); in ClipToOriginalWord()
106 if (blob_box.major_overlap(box)) { in ClipToOriginalWord()
107 original_box += blob_box; in ClipToOriginalWord()
204 TBOX blob_box = other.blobs[i]->bounding_box(); in ProcessMatchedBlobs() local
205 if (blob_box == boxes_[i]) { in ProcessMatchedBlobs()
H A Dratngs.cpp543 TBOX blob_box = tblob->bounding_box(); in SetScriptPositions() local
548 blob_box += tblob->bounding_box(); in SetScriptPositions()
551 script_pos_[blob_index] = ScriptPositionOf(false, *unicharset_, blob_box, uni_id); in SetScriptPositions()
600 const TBOX &blob_box, UNICHAR_ID unichar_id) { in ScriptPositionOf() argument
602 int top = blob_box.top(); in ScriptPositionOf()
603 int bottom = blob_box.bottom(); in ScriptPositionOf()
H A Dpageres.cpp1285 TBOX blob_box = blob_it.data()->bounding_box(); in ComputeBlobEnds() local
1288 blob_box += blob_it.data()->bounding_box(); in ComputeBlobEnds()
1298 blob_end = (blob_box.right() + blob_it.data()->bounding_box().left()) / 2; in ComputeBlobEnds()
1446 TBOX blob_box; in ReplaceCurrentWord() local
1450 blob_box += MoveAndClipBlob(&src_b_it, &dest_it, clip_box); in ReplaceCurrentWord()
1455 blob_box += MoveAndClipBlob(&rej_b_it, &dest_it, clip_box); in ReplaceCurrentWord()
1458 if (blob_box.null_box()) { in ReplaceCurrentWord()
1460 blob_box = MoveAndClipBlob(&fake_b_it, &dest_it, clip_box); in ReplaceCurrentWord()
1462 box_word->InsertBox(i, blob_box); in ReplaceCurrentWord()
H A Dblobs.cpp811 TBOX blob_box = blob->bounding_box(); in BLNormalize() local
812 float mid_x = (blob_box.left() + blob_box.right()) / 2.0f; in BLNormalize()
816 baseline = blob_box.bottom(); in BLNormalize()
817 blob_scale = ClipToRange(kBlnXHeight * 4.0f / (3 * blob_box.height()), scale, scale * 1.5f); in BLNormalize()
H A Dwerd.cpp549 TBOX blob_box = blob->bounding_box(); in AddSelectedOutlines() local
550 if (blob_box.left() > noise_box.left()) { in AddSelectedOutlines()
H A Dblamer.h256 void BlameClassifier(const UNICHARSET &unicharset, const TBOX &blob_box,
/dports/graphics/gimp-app/gimp-2.10.30/app/tools/
H A Dgimpinkoptions-gui.c49 GtkWidget *blob_box; in gimp_ink_options_gui() local
114 blob_box = gimp_prop_enum_icon_box_new (config, "blob-type", in gimp_ink_options_gui()
116 gtk_orientable_set_orientation (GTK_ORIENTABLE (blob_box), in gimp_ink_options_gui()
118 gtk_box_pack_start (GTK_BOX (hbox), blob_box, FALSE, FALSE, 0); in gimp_ink_options_gui()
119 gtk_widget_show (blob_box); in gimp_ink_options_gui()
121 gtk_size_group_add_widget (size_group, blob_box); in gimp_ink_options_gui()
/dports/graphics/tesseract/tesseract-5.0.0/src/ccmain/
H A Dapplybox.cpp330 TBOX blob_box = word_res->box_word->BlobBox(i + blob_count); in ResegmentCharBox() local
331 if (!blob_box.major_overlap(box)) { in ResegmentCharBox()
338 const double current_box_miss_metric = BoxMissMetric(blob_box, box); in ResegmentCharBox()
339 const double next_box_miss_metric = BoxMissMetric(blob_box, *next_box); in ResegmentCharBox()
342 blob_box.print(); in ResegmentCharBox()
350 char_box += blob_box; in ResegmentCharBox()
448 TBOX blob_box = blob->bounding_box(); in ResegmentWordBox() local
449 if (!blob_box.major_overlap(box)) { in ResegmentWordBox()
453 const double current_box_miss_metric = BoxMissMetric(blob_box, box); in ResegmentWordBox()
457 blob_box.print(); in ResegmentWordBox()
[all …]
H A Dtfacepp.cpp132 TBOX blob_box = word->chopped_word->blobs[b]->bounding_box(); in split_and_recog_word() local
133 int gap = blob_box.left() - prev_box.right(); in split_and_recog_word()
218 TBOX blob_box = word2->chopped_word->blobs[0]->bounding_box(); in join_words() local
225 split_pt.x = (prev_box.right() + blob_box.left()) / 2; in join_words()
226 split_pt.y = (prev_box.top() + prev_box.bottom() + blob_box.top() + blob_box.bottom()) / 4; in join_words()
H A Dequationdetect.cpp310 TBOX blob_box = blob->bounding_box(); in IdentifyBlobsToSkip() local
319 if (nextblob_box.left() >= blob_box.right()) { in IdentifyBlobsToSkip()
323 const bool xoverlap = blob_box.major_x_overlap(nextblob_box), in IdentifyBlobsToSkip()
324 yoverlap = blob_box.y_overlap(nextblob_box); in IdentifyBlobsToSkip()
325 const float widthR = static_cast<float>(std::min(nextblob_box.width(), blob_box.width())) / in IdentifyBlobsToSkip()
326 std::max(nextblob_box.width(), blob_box.width()); in IdentifyBlobsToSkip()
327 const float heightR = static_cast<float>(std::min(nextblob_box.height(), blob_box.height())) / in IdentifyBlobsToSkip()
328 std::max(nextblob_box.height(), blob_box.height()); in IdentifyBlobsToSkip()
334 blob_box += nextblob_box; in IdentifyBlobsToSkip()
H A Dreject.cpp270 TBOX blob_box = word->box_word->BlobBox(blobindex); in reject_edge_blobs() local
271 if (blob_box.left() < tessedit_image_border || blob_box.bottom() < tessedit_image_border || in reject_edge_blobs()
272 blob_box.right() + tessedit_image_border > ImageWidth() - 1 || in reject_edge_blobs()
273 blob_box.top() + tessedit_image_border > ImageHeight() - 1) { in reject_edge_blobs()

12