"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/ccmain/ltrresultiterator.cpp" between
tesseract-5.0.0-rc2.tar.gz and tesseract-5.0.0-rc3.tar.gz

About: Tesseract is an Optical Character Recognition (OCR) engine. Release candidate.

ltrresultiterator.cpp  (tesseract-5.0.0-rc2):ltrresultiterator.cpp  (tesseract-5.0.0-rc3)
skipping to change at line 150 skipping to change at line 150
mean_certainty += best_choice->certainty(blob_index_); mean_certainty += best_choice->certainty(blob_index_);
++certainty_count; ++certainty_count;
} }
if (certainty_count > 0) { if (certainty_count > 0) {
mean_certainty /= certainty_count; mean_certainty /= certainty_count;
return ClipToRange(100 + 5 * mean_certainty, 0.0f, 100.0f); return ClipToRange(100 + 5 * mean_certainty, 0.0f, 100.0f);
} }
return 0.0f; return 0.0f;
} }
void LTRResultIterator::RowAttributes(float *row_height, float *descenders,
float *ascenders) const {
*row_height =
it_->row()->row->x_height() + it_->row()->row->ascenders() - it_->row()->r
ow->descenders();
*descenders = it_->row()->row->descenders();
*ascenders = it_->row()->row->ascenders();
}
// Returns the font attributes of the current word. If iterating at a higher // Returns the font attributes of the current word. If iterating at a higher
// level object than words, eg textlines, then this will return the // level object than words, eg textlines, then this will return the
// attributes of the first word in that textline. // attributes of the first word in that textline.
// The actual return value is a string representing a font name. It points // The actual return value is a string representing a font name. It points
// to an internal table and SHOULD NOT BE DELETED. Lifespan is the same as // to an internal table and SHOULD NOT BE DELETED. Lifespan is the same as
// the iterator itself, ie rendered invalid by various members of // the iterator itself, ie rendered invalid by various members of
// TessBaseAPI, including Init, SetImage, End or deleting the TessBaseAPI. // TessBaseAPI, including Init, SetImage, End or deleting the TessBaseAPI.
// Pointsize is returned in printers points (1/72 inch.) // Pointsize is returned in printers points (1/72 inch.)
const char *LTRResultIterator::WordFontAttributes(bool *is_bold, bool *is_italic , const char *LTRResultIterator::WordFontAttributes(bool *is_bold, bool *is_italic ,
bool *is_underlined, bool *is_ monospace, bool *is_underlined, bool *is_ monospace,
 End of changes. 1 change blocks. 
9 lines changed or deleted 0 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)