ccutil/ocrclass.h File Reference

#include <time.h>
#include "host.h"

Go to the source code of this file.

Classes

Defines

Typedefs

Enumerations


Define Documentation

#define BADTIMES_TIMEOUT   7

Definition at line 62 of file ocrclass.h.

#define CHSET_ANSI   0

Definition at line 102 of file ocrclass.h.

#define CHSET_BIG5   136

Definition at line 106 of file ocrclass.h.

#define CHSET_CYRILLIC   204

Definition at line 107 of file ocrclass.h.

#define CHSET_EEUROPE   238

Definition at line 108 of file ocrclass.h.

#define CHSET_KOREAN   129

Definition at line 104 of file ocrclass.h.

#define CHSET_SCHINESE   134

Definition at line 105 of file ocrclass.h.

#define CHSET_SHIFT_JIS   128

Definition at line 103 of file ocrclass.h.

#define EUC_BOLD   1

Definition at line 117 of file ocrclass.h.

Referenced by write_shm_text().

#define EUC_ITALIC   2

Definition at line 118 of file ocrclass.h.

Referenced by write_shm_text().

#define EUC_SUBSCRIPT   8

Definition at line 120 of file ocrclass.h.

#define EUC_SUPERSCRIPT   16

Definition at line 121 of file ocrclass.h.

#define EUC_UNDERLINE   4

Definition at line 119 of file ocrclass.h.

#define FFAM_MODERN   3

Definition at line 99 of file ocrclass.h.

#define FFAM_NONE   0

Definition at line 96 of file ocrclass.h.

#define FFAM_ROMAN   1

Definition at line 97 of file ocrclass.h.

#define FFAM_SWISS   2

Definition at line 98 of file ocrclass.h.

#define IMAGE_ROUNDING   32

Definition at line 41 of file ocrclass.h.

#define LANGE_ALBANIAN   0x041c

Definition at line 67 of file ocrclass.h.

#define LANGE_BRITISH   0x0809

Definition at line 68 of file ocrclass.h.

#define LANGE_BULGARIAN   0x0402

Definition at line 69 of file ocrclass.h.

#define LANGE_CROATIAN   0x041a

Definition at line 70 of file ocrclass.h.

#define LANGE_CZECH   0x0405

Definition at line 71 of file ocrclass.h.

#define LANGE_DANISH   0x0406

Definition at line 72 of file ocrclass.h.

#define LANGE_DUTCH   0x0413

Definition at line 73 of file ocrclass.h.

#define LANGE_FINNISH   0x040b

Definition at line 74 of file ocrclass.h.

#define LANGE_FRENCH   0x040c

Definition at line 75 of file ocrclass.h.

#define LANGE_GERMAN   0x0407

Definition at line 76 of file ocrclass.h.

#define LANGE_GREEK   0x0408

Definition at line 77 of file ocrclass.h.

#define LANGE_HUNGARIAN   0x040e

Definition at line 78 of file ocrclass.h.

#define LANGE_ITALIAN   0x0410

Definition at line 79 of file ocrclass.h.

#define LANGE_JAPANESE   0x0411

Definition at line 80 of file ocrclass.h.

#define LANGE_KOREAN   0x0412

Definition at line 81 of file ocrclass.h.

#define LANGE_NONE   0x0400

Definition at line 66 of file ocrclass.h.

Referenced by ocr_error().

#define LANGE_NORWEGIAN   0x0414

Definition at line 82 of file ocrclass.h.

#define LANGE_POLISH   0x0415

Definition at line 83 of file ocrclass.h.

#define LANGE_PORTUGESE   0x0416

Definition at line 84 of file ocrclass.h.

#define LANGE_ROMANIAN   0x0418

Definition at line 85 of file ocrclass.h.

#define LANGE_RUSSIAN   0x0419

Definition at line 86 of file ocrclass.h.

#define LANGE_SCHINESE   0x0804

Definition at line 87 of file ocrclass.h.

#define LANGE_SLOVAK   0x041b

Definition at line 88 of file ocrclass.h.

#define LANGE_SPANISH   0x040a

Definition at line 89 of file ocrclass.h.

#define LANGE_SWEDISH   0x041d

Definition at line 90 of file ocrclass.h.

#define LANGE_TCHINESE   0x0404

Definition at line 91 of file ocrclass.h.

#define LANGE_TURKISH   0x041f

Definition at line 92 of file ocrclass.h.

#define LANGE_USENGLISH   0x0409

Definition at line 93 of file ocrclass.h.

#define MAX_FONT_NAME   34

Note:
File: ocrclass.h
  • Class definitions and constants for the OCR API.
  • This file contains typedefs for all the structures used by the HP OCR interface.
  • The code is designed to be used with either a C or C++ compiler. The structures are designed to allow them to be used with any structure alignment up to 8.
Author:
Hewlett-Packard Co
Date:
1996
 * (C) Copyright 1996, Hewlett-Packard Co.
 ** Licensed under the Apache License, Version 2.0 (the "License");
 ** you may not use this file except in compliance with the License.
 ** You may obtain a copy of the License at
 ** http://www.apache.org/licenses/LICENSE-2.0
 ** Unless required by applicable law or agreed to in writing, software
 ** distributed under the License is distributed on an "AS IS" BASIS,
 ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 ** See the License for the specific language governing permissions and
 ** limitations under the License.

Definition at line 35 of file ocrclass.h.

Referenced by ocr_append_fontinfo().

#define MAX_OCR_NAME   32

Definition at line 36 of file ocrclass.h.

Referenced by ocr_setup_startinfo(), and ocr_setup_startinfo_ansi().

#define MAX_OCR_VERSION   17

Definition at line 37 of file ocrclass.h.

Referenced by ocr_setup_startinfo(), and ocr_setup_startinfo_ansi().

#define MIN_IMAGE_SIZE   64

Definition at line 40 of file ocrclass.h.

#define OCR_API_BAD_CHAR   (-3)

Definition at line 159 of file ocrclass.h.

Referenced by ocr_append_char().

#define OCR_API_BAD_STATE   (-4)

Definition at line 160 of file ocrclass.h.

Referenced by ocr_append_char(), ocr_append_fontinfo(), ocr_open_shm(), ocr_send_text(), ocr_setup_startinfo(), and ocr_setup_startinfo_ansi().

#define OCR_API_NO_MEM   (-2)

Definition at line 158 of file ocrclass.h.

Referenced by ocr_append_char(), and ocr_append_fontinfo().

#define PITCH_DEF   0

Definition at line 111 of file ocrclass.h.

#define PITCH_FIXED   1

Definition at line 112 of file ocrclass.h.

#define PITCH_VAR   2

Definition at line 113 of file ocrclass.h.

#define PROGRESS_TIMEOUT   3

Definition at line 61 of file ocrclass.h.

#define READIM_TIMEOUT   10

Definition at line 59 of file ocrclass.h.

Referenced by ocr_get_first_image_strip(), and ocr_get_next_image_strip().

#define READTEXT_TIMEOUT   5

Definition at line 60 of file ocrclass.h.

Referenced by ocr_send_text().

#define RELEASE_TIMEOUT   5

Definition at line 58 of file ocrclass.h.

Referenced by release_ocr().

#define SENDIM_TIMEOUT   5

Definition at line 57 of file ocrclass.h.

#define SHUTDOWN_TIMEOUT   6

Definition at line 56 of file ocrclass.h.

#define STARTUP_TIMEOUT   10

Definition at line 55 of file ocrclass.h.


Typedef Documentation

typedef bool(*) CANCEL_FUNC(void *cancel_this, int words)

Definition at line 290 of file ocrclass.h.


Enumeration Type Documentation

enum OCR_CHAR_DIRECTION

Character rendering directions.

Enumerator:
OCR_CDIR_RIGHT_LEFT 
OCR_CDIR_LEFT_RIGHT 
OCR_CDIR_TOP_BOTTOM 
OCR_CDIR_BOTTOM_TOP 

Definition at line 127 of file ocrclass.h.

00128 {
00129   OCR_CDIR_RIGHT_LEFT,           /* right to left horizontal */
00130   OCR_CDIR_LEFT_RIGHT,           /* left to right horizontal */
00131   OCR_CDIR_TOP_BOTTOM,           /* top to bottom vertical */
00132   OCR_CDIR_BOTTOM_TOP            /* bottom to top vertical */
00133 };

enum OCR_ERR_CODE

Error codes used for passing errors back to the HP side.

Enumerator:
OCR_ERR_NONE 
OCR_ERR_CLEAN_EXIT 
OCR_ERR_NO_MEM 
OCR_ERR_FILE_READ 
OCR_ERR_TMP_WRITE 
OCR_ERR_TMP_READ 
OCR_ERR_BAD_DLL 
OCR_ERR_BAD_EXE 
OCR_ERR_BAD_LOAD 
OCR_ERR_BAD_LANG 
OCR_ERR_BAD_STATE 
OCR_ERR_INTERNAL1 
OCR_ERR_INTERNAL2 
OCR_ERR_INTERNAL3 
OCR_ERR_INTERNAL4 
OCR_ERR_INTERNAL5 
OCR_ERR_INTERNAL6 
OCR_ERR_INTERNAL7 
OCR_ERR_INTERNAL8 
OCR_ERR_TIMEOUT 

Definition at line 166 of file ocrclass.h.

00167 {
00168   OCR_ERR_NONE,                  /* no error */
00169   OCR_ERR_CLEAN_EXIT,            /* no error */
00170   OCR_ERR_NO_MEM,                /* out of memory */
00171   OCR_ERR_FILE_READ,             /* failed to read data file */
00172   OCR_ERR_TMP_WRITE,             /* failed to write temp file */
00173   OCR_ERR_TMP_READ,              /* failed to read temp file */
00174   OCR_ERR_BAD_DLL,               /* missing or invalid dll subcomponent */
00175   OCR_ERR_BAD_EXE,               /* missing or invalid exe subcomponent */
00176   OCR_ERR_BAD_LOAD,              /* failed to load subcomponent */
00177   OCR_ERR_BAD_LANG,              /* unable to recognize requested language */
00178   OCR_ERR_BAD_STATE,             /* engine did call out of sequence */
00179   OCR_ERR_INTERNAL1,             /* internal error type 1 */
00180   OCR_ERR_INTERNAL2,             /* internal error type 1 */
00181   OCR_ERR_INTERNAL3,             /* internal error type 1 */
00182   OCR_ERR_INTERNAL4,             /* internal error type 1 */
00183   OCR_ERR_INTERNAL5,             /* internal error type 1 */
00184   OCR_ERR_INTERNAL6,             /* internal error type 1 */
00185   OCR_ERR_INTERNAL7,             /* internal error type 1 */
00186   OCR_ERR_INTERNAL8,             /* internal error type 1 */
00187   OCR_ERR_TIMEOUT                /* timed out in comms */
00188 };                               /*for calls to ocr_error */

enum OCR_LINE_DIRECTION

Line rendering direction.

Enumerator:
OCR_LDIR_DOWN_RIGHT 
OCR_LDIR_UP_LEFT 

Definition at line 139 of file ocrclass.h.

00140 {
00141   OCR_LDIR_DOWN_RIGHT,           /* horizontal lines go down */
00142   /*vertical lines go right */
00143   OCR_LDIR_UP_LEFT               /* horizontal lines go up */
00144 };

enum OCR_NEWLINE_TYPE

Newline type.

Enumerator:
OCR_NL_NONE 
OCR_NL_NEWLINE 
OCR_NL_NEWPARA 

Definition at line 150 of file ocrclass.h.

00151 {
00152   OCR_NL_NONE,                   // not a newline
00153   OCR_NL_NEWLINE,                // this is a newline but not new para
00154   OCR_NL_NEWPARA                 // this is a newline and a new para
00155 };


Generated on Wed Feb 28 19:49:17 2007 for Tesseract by  doxygen 1.5.1