PreprocessScannedPageRange
Rendering and image preprocessing
Description
Applies the scanned-page cleanup pipeline of PreprocessScannedPage across a 1-based page range list such as "1-3,5"
Syntax
Delphi
Function TPDFlib.PreprocessScannedPageRange(Const PageRange: WideString; DPI: Double= 150; Options: Integer= 15; SauvolaWindow: Integer= 15; SauvolaK: Double= 0.2): Integer;
Parameters
| PageRange | Page range specification (for example "1-5,8") or empty string for all pages |
|---|---|
| DPI | Target rasterisation resolution in dots per inch (clamped to 72..600) |
| Options | Bitmask of preprocessing stages matching PreprocessScannedPage |
| SauvolaWindow | Local window radius in pixels for Sauvola thresholding (default 15) |
| SauvolaK | Sauvola sensitivity factor (default 0.2) |
Return values
| >= 1 | The number of pages successfully preprocessed |
|---|---|
| 0 | No pages matched the range or preprocessing failed |
Remarks
Preserves the original page selection after processing all pages in the range