2
Copyright (c) 1993-2008, Cognitive Technologies
5
����������� ��������� ��������������� � ������������� ��� � ���� ��������� ����,
6
��� � � �������� �����, � ����������� ��� ���, ��� ���������� ��������� �������:
8
* ��� ��������� ��������������� ��������� ���� ������ ���������� ���������
9
���� ����������� �� ��������� �����, ���� ������ ������� � �����������
11
* ��� ��������� ��������������� ��������� ���� � ������������ �/��� �
12
������ ����������, ������������ ��� ���������������, ������ �����������
13
��������� ���� ���������� �� ��������� �����, ���� ������ ������� �
14
����������� ����� �� ��������.
15
* �� �������� Cognitive Technologies, �� ����� �� ����������� �� �����
16
���� ������������ � �������� �������� ��������� �/��� �����������
17
���������, ���������� �� ���� ��, ��� ���������������� �����������
20
��� ��������� ������������� ����������� ��������� ���� �/��� ������� ������ "���
21
��� ����" ��� ������-���� ���� ��������, ���������� ���� ��� ���������������,
22
������� �������� ������������ �������� � ����������� ��� ���������� ����, �� ��
23
������������� ���. �� �������� ��������� ���� � �� ���� ������ ����, �������
24
����� �������� �/��� �������� �������������� ���������, �� � ���� ������ ��
25
��Ѩ� ���������������, ������� ����� �����, ���������, ����������� ���
26
������������� ������, ��������� � �������������� ��� ���������� ����������
27
������������� ������������� ��������� (������� ������ ������, ��� ������,
28
������� ���������, ��� ������ �/��� ������ �������, ���������� ��-�� ��������
29
������� ��� �/��� ������ ��������� �������� ��������� � ������� �����������,
30
�� �� ������������� ����� ��������), �� �� ������������� ���, ���� ���� �����
31
�������� ��� ������ ���� ���� �������� � ����������� ����� ������� � ������.
33
Redistribution and use in source and binary forms, with or without modification,
34
are permitted provided that the following conditions are met:
36
* Redistributions of source code must retain the above copyright notice,
37
this list of conditions and the following disclaimer.
38
* Redistributions in binary form must reproduce the above copyright notice,
39
this list of conditions and the following disclaimer in the documentation
40
and/or other materials provided with the distribution.
41
* Neither the name of the Cognitive Technologies nor the names of its
42
contributors may be used to endorse or promote products derived from this
43
software without specific prior written permission.
45
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
46
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
47
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
48
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
49
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
50
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
51
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
52
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
53
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
54
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
58
//# include "layout.h"
59
//# include "extract.h"
60
//# include "kernel.h"
61
//# include "status.h"
65
//# include "pumadef.h"
67
//////////////////////////////////
68
Handle hDebugPictures = NULL;
69
Handle hRectanglePictures = NULL;
70
Handle hPolyPictures = NULL;
71
Handle hShowFirstAttempt = NULL;
72
Handle hShowAllGreat = NULL;
73
Handle hShowAllCancelledGreat = NULL;
74
Handle hShowCheckLetters = NULL;
75
Handle hShowBigLetters = NULL;
76
Handle hShowPossiblePics = NULL;
77
//Handle hDebugStrings = NULL;
78
//////////////////////////////////
83
LDPUMA_Registry(&hDebugPictures,"��������� ��������...",NULL);
84
//LDPUMA_RegVariable(hDebugLayout,"���������� ������� �������.",&layout,"unsigned char");
85
LDPUMA_RegistryHelp(hDebugPictures,"������ ��������� ��������",FALSE);
87
LDPUMA_Registry(&hShowPossiblePics,"�������� ����������� �������� 1",hDebugPictures);
88
LDPUMA_RegistryHelp(hShowPossiblePics,"���������� ����������� ��������, ���������� \
89
����� ������� �������.",FALSE);
91
LDPUMA_Registry(&hShowBigLetters,"�������� �������",hDebugPictures);
92
LDPUMA_RegistryHelp(hShowBigLetters,"���������� �������.",FALSE);
95
LDPUMA_Registry(&hRectanglePictures,"�������� ����� ������������� ��������",hDebugPictures);
96
LDPUMA_RegistryHelp(hRectanglePictures,"�������� ����� ������������� �������� \
97
(��������������� ������ ��������).",FALSE);
99
LDPUMA_Registry(&hPolyPictures,"�������� ����� ��������������� ��������",hDebugPictures);
100
LDPUMA_RegistryHelp(hPolyPictures,"�������� ����� ��������������� ��������. \
101
(������������� ������ ��������).",FALSE);
103
LDPUMA_Registry(&hShowAllGreat,"�������� ��� ������ ���������� 1",hDebugPictures);
104
LDPUMA_RegistryHelp(hShowAllGreat,"���������� ��� ������ ����������, \
105
�� ������� �� ������ ������� ����� ���������� ��������.",FALSE);
107
LDPUMA_Registry(&hShowAllCancelledGreat,"�������� ��� ������������� ������ ���������� 1",hDebugPictures);
108
LDPUMA_RegistryHelp(hShowAllCancelledGreat,"���������� ��� ������������� ������ ����������, \
109
�� ������� �� ������ ������� ����� ���������� ��������.",FALSE);
111
LDPUMA_Registry(&hShowCheckLetters,"�������� �������� �� ��������� 1",hDebugPictures);
112
LDPUMA_RegistryHelp(hShowCheckLetters,"���������� ������� �������� �� ���������",FALSE);
114
LDPUMA_Registry(&hShowFirstAttempt,"�������� �������� 1",hDebugPictures);
115
LDPUMA_RegistryHelp(hShowFirstAttempt,"���������� ��������, ���������� \
116
����� ������� �������.",FALSE);
119
#define REGVAR(a) LDPUMA_RegVariable(hDebugLayout,#a,&a,"short int")
122
LDPUMA_RegVariable(hDebugLayout,"LT_DebugGraphicsLevel",<_DebugGraphicsLevel,"int");
124
REGVAR(bDebugTimeFlag);
125
REGVAR(bDebugOptionCalibratePictureRemovingCriteria);
126
REGVAR(bDebugOptionCalibrateDD_RemovingCriteria);
127
REGVAR(bDebugOptionCalibrateLinearRemovingCriteria);
129
REGVAR(bOptionForceOneColumn);
130
REGVAR(bOptionBusinessCardsLayout);
131
REGVAR(bOptionPointSizeAnalysis);
132
REGVAR(bOptionSmartBreaking);
133
REGVAR(bOptionInitialBreakingByPageMatrix);
134
REGVAR(bOptionBlocksRemovingByPageMatrix);
135
REGVAR(bOptionBlocksRemovingByDustDistribution);
136
REGVAR(bOptionSpecialHorizontalCutting);
137
REGVAR(bOptionWhiteStripsBreaking);
139
REGVAR(SE_DebugGraphicsLevel);
142
REGVAR(MA_DebugLevel);
149
/////////////////////////////////////////
153
#define UNREGVAR(a) LDPUMA_UnregVariable(&a)
156
LDPUMA_UnregVariable(<_DebugGraphicsLevel);
158
UNREGVAR(bDebugTimeFlag);
159
UNREGVAR(bDebugOptionCalibratePictureRemovingCriteria);
160
UNREGVAR(bDebugOptionCalibrateDD_RemovingCriteria);
161
UNREGVAR(bDebugOptionCalibrateLinearRemovingCriteria);
163
UNREGVAR(bOptionForceOneColumn);
164
UNREGVAR(bOptionBusinessCardsLayout);
165
UNREGVAR(bOptionPointSizeAnalysis);
166
UNREGVAR(bOptionSmartBreaking);
167
UNREGVAR(bOptionInitialBreakingByPageMatrix);
168
UNREGVAR(bOptionBlocksRemovingByPageMatrix);
169
UNREGVAR(bOptionBlocksRemovingByDustDistribution);
170
UNREGVAR(bOptionSpecialHorizontalCutting);
171
UNREGVAR(bOptionWhiteStripsBreaking);
173
UNREGVAR(SE_DebugGraphicsLevel);
176
UNREGVAR(MA_DebugLevel);
182
////////////////////////////////////////