PagePreprocessingParams Object (IPagePreprocessingParams Interface)
This object is used for tuning different parameters of page preprocessing. Page preprocessing is performed before page analysis. This stage includes correction of page orientation, image inversion, and removal of geometrical distortions. A pointer to this object is passed as a member of the PageProcessingParams object into processing methods.
The PagePreprocessingParams object is a persistent object. This means that the object's current state can be written to persistent storage: an area in the global memory or a disk file. Later, the object can be re-created by reading the object's state from persistent storage. The following methods provide persistence of the object: SaveToFile, LoadFromFile, SaveToMemory, and LoadFromMemory.
Properties
| Name | Type | Description |
|---|---|---|
| Application | Engine, read-only | Returns the Engine object. |
| BackgroundWhitening | ThreeStatePropertyValueEnum |
Specifies if image background should be whitened. This property is TSPV_Auto by default. In default mode, ABBYY FineReader Engine whitens the background. |
| CorrectGeometry | ThreeStatePropertyValueEnum |
Specifies whether geometrical distortions (perspective on photos, curved lines from scanned books, etc.) should be removed during page preprocessing. This property is TSPV_Auto by default. In default mode, ABBYY FineReader Engine corrects geometry for photographs. |
| CorrectInvertedImage | ThreeStatePropertyValueEnum |
Specifies if inverted image should be corrected. This property is TSPV_Auto by default. In default mode, ABBYY FineReader Engine corrects inverted images. |
| CorrectOrientationMode | CorrectOrientationModeEnum |
Specifies how image orientation should be corrected during preprocessing. The default value is COM_Auto, which means orientation will be determined and corrected automatically if needed. |
| CorrectSkewMode | CorrectSkewModeEnum |
If this property is set to CSM_Auto or CSM_Fast, image skew will be corrected during page preprocessing.
By default, this property is set to CSM_Auto, which means precise skew correction. |
| CropImage | ThreeStatePropertyValueEnum |
If this property is set to TSPV_Yes, during preprocessing ABBYY FineReader Engine will detect document edges on the image and crop the image accordingly.
The default value of this property is TSPV_Auto. In the default mode, ABBYY FineReader Engine crops the image or skips this step automatically, depending on the source of the processed image. |
| DetectImageType | ThreeStatePropertyValueEnum |
Specifies how the image type is determined. Works in conjunction with ImageSourceType. Default: TSPV_Auto (effective only when ImageSourceType = IST_Auto).
|
| DiscardColorImage | VARIANT_BOOL |
This property set to TRUE tells ABBYY FineReader Engine to leave only black-and-white plane in the prepared image. In this case, image binarization is performed during image preprocessing. By default, this property is set to FALSE. |
| OverwriteResolutionMode | OverwriteResolutionEnum |
If this property is set to ORM_Auto, ABBYY FineReader Engine will automatically detect and overwrite image resolution. If it is set to ORM_Manual, use the ResolutionToOverwrite property to specify the new image resolution. The new resolution will be applied before all other stages of image preparation (such as binarization, skew correction, etc.).
By default, the value of the property is ORM_Auto. |
| ResolutionToOverwrite | int |
This value is used to overwrite resolution of the preprocessed image if the OverwriteResolutionMode property is ORM_Manual. Note that the default value of this property is 0, so you must set the desired value yourself. If you set OverwriteResolutionMode to ORM_Manual and don't set the value for this property, an error will occur. |
| SplitType | PageSplitTypeEnum | Specifies the parameters of page splitting. |
| StraightenLinesMode | StraightenLinesModeEnum |
Specifies how lines will be straightened. This property is SLM_Auto by default. In this case new neural network algorithm would be used. |
| UseFastBinarization | VARIANT_BOOL |
If this property is TRUE, ABBYY FineReader Engine will use algorithms for fast image binarization. Binarization is performed either during preprocessing (if DiscardColorImage is TRUE), or later when a black-and-white image is necessary (e.g., when you call the IImageDocument::BlackWhiteImage property for an open image document for the first time). This property set to TRUE will speed up binarization; however, its quality may deteriorate. By default, the value of this property is FALSE. |
Methods
| Name | Description |
|---|---|
| CopyFrom | Initializes properties of the current object with values of similar properties of another object. |
| LoadFromFile | Restores the object contents from a file on disk. |
| LoadFromMemory | Restores the object contents from the global memory. |
| SaveToFile | Saves the object contents into a file on disk. |
| SaveToMemory | Saves the object contents into the global memory. |
Related objects

Output parameter
This object is the output parameter of the CreatePagePreprocessingParams method of the Engine object.
Input parameter
This object is passed as an input parameter to the following methods:
- Preprocess, PreprocessPages methods of the FRDocument object
- Preprocess method of the FRPage object
Samples
The object is used in the following code samples: CommandLineInterface; and demo tools: Classification.
See also
Tuning Parameters of Preprocessing, Analysis, Recognition, and Synthesis
11/7/2025 12:48:30 PM
