1 #ifndef TESSERACT_API_CAPI_H__
2 #define TESSERACT_API_CAPI_H__
4 #ifdef TESS_CAPI_INCLUDE_BASEAPI
19 # define TESS_CALL __cdecl
31 #ifdef TESS_CAPI_INCLUDE_BASEAPI
54 typedef struct TessBaseAPI TessBaseAPI;
55 typedef struct TessPageIterator TessPageIterator;
56 typedef struct TessResultIterator TessResultIterator;
57 typedef struct TessMutableIterator TessMutableIterator;
69 typedef struct Pix PIX;
70 typedef struct Boxa BOXA;
71 typedef struct Pixa PIXA;
81 #ifdef TESS_CAPI_INCLUDE_BASEAPI
105 #ifdef TESS_CAPI_INCLUDE_BASEAPI
109 #ifdef TESS_CAPI_INCLUDE_BASEAPI
110 TESS_API int TESS_CALL TessBaseAPIInit(TessBaseAPI* handle,
const char* datapath,
const char* language,
111 TessOcrEngineMode
mode,
char** configs,
int configs_size,
112 const STRING* vars_vec,
size_t vars_vec_size,
113 const STRING* vars_values,
size_t vars_values_size,
BOOL set_only_init_params);
116 char** configs,
int configs_size);
138 int bytes_per_pixel,
int bytes_per_line,
139 int left,
int top,
int width,
int height);
144 int bytes_per_pixel,
int bytes_per_line);
151 #ifdef TESS_CAPI_INCLUDE_BASEAPI
173 int timeout_millisec);
175 const char* retry_config,
int timeout_millisec);
196 #ifdef TESS_CAPI_INCLUDE_BASEAPI
199 TESS_API void TESS_CALL TessBaseAPISetFillLatticeFunc(TessBaseAPI* handle, TessFillLatticeFunc
f);
203 int* num_features,
int* FeatureOutlineIndex);
207 int* unichar_ids,
float* ratings,
int* num_matches_returned);
213 #ifdef TESS_CAPI_INCLUDE_BASEAPI
219 #ifdef TESS_CAPI_INCLUDE_BASEAPI
234 #ifdef TESS_CAPI_INCLUDE_BASEAPI
251 TessPageIteratorLevel element);
254 int* left,
int* top,
int* right,
int* bottom);
260 int* left,
int* top);
263 int* x1,
int* y1,
int* x2,
int* y2);
266 TessWritingDirection *writing_direction, TessTextlineOrder *textline_order,
267 float *deskew_angle);
284 BOOL* is_underlined,
BOOL* is_monospace,
BOOL* is_serif,
285 BOOL* is_smallcaps,
int* pointsize,
int* font_id);