tesseract  v4.0.0-17-g361f3264
Open Source OCR Engine
edgloop.h
1 /**********************************************************************
2  * File: edgloop.h (Formerly edgeloop.h)
3  * Description: Functions to clean up an outline before approximation.
4  * Author: Ray Smith
5  * Created: Tue Mar 26 16:56:25 GMT 1991
6  *
7  * (C) Copyright 1991, Hewlett-Packard Ltd.
8  ** Licensed under the Apache License, Version 2.0 (the "License");
9  ** you may not use this file except in compliance with the License.
10  ** You may obtain a copy of the License at
11  ** http://www.apache.org/licenses/LICENSE-2.0
12  ** Unless required by applicable law or agreed to in writing, software
13  ** distributed under the License is distributed on an "AS IS" BASIS,
14  ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  ** See the License for the specific language governing permissions and
16  ** limitations under the License.
17  *
18  **********************************************************************/
19 
20 #ifndef EDGLOOP_H
21 #define EDGLOOP_H
22 
23 #include "scrollview.h"
24 #include "params.h"
25 #include "pdblock.h"
26 #include "coutln.h"
27 #include "crakedge.h"
28 
29 #define BUCKETSIZE 16
30 
31 
32 extern INT_VAR_H (edges_children_per_grandchild, 10,
33 "Importance ratio for chucking outlines");
34 extern INT_VAR_H (edges_children_count_limit, 45,
35 "Max holes allowed in blob");
36 extern double_VAR_H (edges_childarea, 0.5,
37 "Max area fraction of child outline");
38 extern double_VAR_H (edges_boxarea, 0.8,
39 "Min area fraction of grandchild for box");
40 void complete_edge(CRACKEDGE *start, //start of loop
41  C_OUTLINE_IT* outline_it);
42 ScrollView::Color check_path_legal( //certify outline
43  CRACKEDGE *start //start of loop
44  );
45 int16_t loop_bounding_box( //get bounding box
46  CRACKEDGE *&start, //edge loop
47  ICOORD &botleft, //bounding box
48  ICOORD &topright);
49 #endif
Color
Definition: scrollview.h:105
Definition: crakedge.h:26
integer coordinate
Definition: points.h:32