* Get a mutable iterator to the results of LayoutAnalysis and/or Recognize. * The returned iterator must be deleted after use. * WARNING! This class points to data held within the TessBaseAPI class, and * therefore can only be used while the TessBaseAPI class still exists and * has not been subjected to a call of Init, SetImage, Recognize, Clear, End * DetectOS, or anything else that changes
| 1269 | * DetectOS, or anything else that changes the internal PAGE_RES. |
| 1270 | */ |
| 1271 | MutableIterator* TessBaseAPI::GetMutableIterator() { |
| 1272 | if (tesseract_ == NULL || page_res_ == NULL) |
| 1273 | return NULL; |
| 1274 | return new MutableIterator(page_res_, tesseract_, |
| 1275 | thresholder_->GetScaleFactor(), |
| 1276 | thresholder_->GetScaledYResolution(), |
| 1277 | rect_left_, rect_top_, rect_width_, rect_height_); |
| 1278 | } |
| 1279 | |
| 1280 | /** Make a text string from the internal data structures. */ |
| 1281 | char* TessBaseAPI::GetUTF8Text() { |