Hi Dimitry, with the guidelines provided from you, I prepared a strong
cup of coffee and start reading the top part of baseapi.h

Q1
Init(datapath, language, OcrEngineMode);
What is the normal setting of OcrEngineMode?

I try to use the :Recognize(ETEXT_DESC* monitor) method.
>>> There are two PARTS to the Recognize method

Part ONE:
Q2: which of the following is USED In normal running mode of
tessearct.exe to recognize text

 if (tesseract_->tessedit_resegment_from_line_boxes)
    page_res_ = tesseract_->ApplyBoxes(*input_file_, true,
block_list_);
  else if (tesseract_->tessedit_resegment_from_boxes)
    page_res_ = tesseract_->ApplyBoxes(*input_file_, false,
block_list_);
  else
    page_res_ = new PAGE_RES(block_list_, &tesseract_-
>prev_word_best_choice_);  <<My guess>
  if (tesseract_->tessedit_make_boxes_from_boxes) {
    tesseract_->CorrectClassifyWords(page_res_);
    return 0;
  }

Part TWO:
Q3: which of the following is USED In normal running mode of
tessearct.exe to recognize text
if (tesseract_->interactive_mode) {
    tesseract_->pgeditor_main(rect_width_, rect_height_, page_res_);
    // The page_res is invalid after an interactive session, so
cleanup
    // in a way that lets us continue to the next page without
crashing.
    delete page_res_;
    page_res_ = NULL;
    return -1;
  } else if (tesseract_->tessedit_train_from_boxes) {
    tesseract_->ApplyBoxTraining(*output_file_, page_res_);
  } else if (tesseract_->tessedit_ambigs_training) {
    FILE *training_output_file = tesseract_-
>init_recog_training(*input_file_);
    // OCR the page segmented into words by tesseract.
    tesseract_->recog_training_segmented(
        *input_file_, page_res_, monitor, training_output_file);
    fclose(training_output_file);
  } else {
    // Now run the main recognition.
    tesseract_->recog_all_words(page_res_, monitor, NULL, NULL, 0);
<<My guess>
  }

-- 
You received this message because you are subscribed to the Google Groups 
"tesseract-ocr" group.
To post to this group, send email to tesseract-ocr@googlegroups.com.
To unsubscribe from this group, send email to 
tesseract-ocr+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/tesseract-ocr?hl=en.

Reply via email to