00001 00002 // File: cutil.h 00003 // Description: cutil class. 00004 // Author: Samuel Charron 00005 // 00006 // (C) Copyright 2006, Google Inc. 00007 // Licensed under the Apache License, Version 2.0 (the "License"); 00008 // you may not use this file except in compliance with the License. 00009 // You may obtain a copy of the License at 00010 // http://www.apache.org/licenses/LICENSE-2.0 00011 // Unless required by applicable law or agreed to in writing, software 00012 // distributed under the License is distributed on an "AS IS" BASIS, 00013 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00014 // See the License for the specific language governing permissions and 00015 // limitations under the License. 00016 // 00018 00019 #ifndef TESSERACT_CUTIL_CUTIL_CLASS_H__ 00020 #define TESSERACT_CUTIL_CUTIL_CLASS_H__ 00021 00022 #include "ccutil.h" 00023 #include "tessclas.h" 00024 #include "const.h" 00025 #include "strngs.h" 00026 00027 namespace tesseract { 00028 00029 class CUtil : public CCUtil { 00030 public: 00031 CUtil(); 00032 ~CUtil(); 00033 void read_variables(const char *filename, bool global_only); 00034 public: 00035 TBLOB *pageblobs; /*first blob on page */ 00036 TEXTBLOCK *pageblocks; /*first block on page */ 00037 00038 int resolution; /*scanner res in dpi */ 00039 int acts[MAXPROC]; /*action flags */ 00040 int debugs[MAXPROC]; /*debug flags */ 00041 int plots[MAXPROC]; /*plot flags */ 00042 00043 int corners[4]; /*corners of scan window */ 00044 00045 char *debugfile; /* debug file name */ 00046 00047 int plots_fx; 00048 int plots_ocr; 00049 00050 int debugs_fx; 00051 int debugs_ocr; 00052 00053 int acts_fx; 00054 int acts_ocr; 00055 00056 char *demodir; /*demo home directory */ 00057 }; 00058 00059 } // namespace tesseract 00060 00061 #endif // TESSERACT_CUTIL_CUTIL_CLASS_H__