DOC2PREPROCESSINGOPTIONS

typedef struct _tagDOC2PREPROCESSINGOPTIONS 
{ 
   L_UINT32 uStructSize; 
   DOC2_CONVERSIONMODE BinarizationMode; 
   DOC2_INVERTMODE InvertMode; 
   DOC2_ROTATEMODE RotationMode; 
   L_BOOL EnableDespeckleMode; 
   L_INT nBrightness; 
   L_INT nThreshold; 
} DOC2PREPROCESSINGOPTIONS, * pDOC2PREPROCESSINGOPTIONS; 

The DOC2PREPROCESSINGOPTIONS structure provides information about some pre-processing settings.

Member Description
uStructSize Structure size. It should be equal to sizeof(DOC2PREPROCESSINGOPTIONS).
BinarizationMode This member will influence how a non-B/W image, which is stored in the engine, will be converted to a B/W image. For a list of possible values, refer to DOC2_CONVERSIONMODE.
InvertMode This member specifies which image inversion mode will be used during the forthcoming image processing processes. The image inversion mode can be either automatic, switched on, or switched off (white-on-black to black-on-white). For a list of possible values, refer to DOC2_INVERTMODE.
RotationMode This member specifies which image rotation mode will be used during a forthcoming image processing process. The image rotation mode can be automatic, switched off, or programmable. For a list of possible values, refer to DOC2_ROTATEMODE.
EnableDespeckleMode This member specifies the engines image despeckle mode, i.e. whether the adaptive noise removal algorithm is to be activated implicitly when the current image is a B/W image. The noise removal algorithm runs only on B/W images with a resolution of 280 DPI or higher. This setting might influence the recognition accuracy. Possible values are:
  Value Meaning
  TRUE Activate the adaptive noise removal algorithm.
  FALSE Deactivate the adaptive noise removal algorithm.
nBrightness This member fine tunes the threshold calculation in the automatic adaptive image conversion mode when the BinarizationMode member  is set to DOC2_CONVERSION_AUTO. This will influence the brightness/darkness of the resulting B/W image during the forthcoming image processing process. Valid values are range between 0 to 100.
nThreshold This member specifies the threshold parameter of an image conversion to a B/W image. The parameter has an effect only when the BinarizationMode member  is set to DOC2_CONVERSION_SET. This setting is used during a forthcoming image processing process.

Comments

pDOC2PREPROCESSINGOPTIONS is a pointer to a DOC2PREPROCESSINGOPTIONS structure. If the function parameter type is pDOC2PREPROCESSINGOPTIONS, declare a DOC2PREPROCESSINGOPTIONS variable, update the structure's fields, and pass the variable's address in the parameter. Declaring a pDOC2PREPROCESSINGOPTIONS variable is necessary only if the program requires a pointer.

This structure is used with the following functions:

L_Doc2GetPreProcessingOptions

L_Doc2SetPreProcessingOptions

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS Professional OCR C API Help