Chapter Contents |
Previous |
Next |
Image Data Model: _threshold |
Syntax | |
Details |
Syntax |
CALL SEND (object-id, '_threshold', value); |
Argument | Type | Description | |
---|---|---|---|
value |
N | a threshold value for converting standard RGB values to monochrome: | |
1...255 | sets the threshold that determines whether a color maps to black or to white | ||
0 | defaults to 128 | ||
-1 | calculates the threshold value by averaging all pixels in the image. |
Details |
The _threshold method allows documents that are scanned in color to be converted to monochrome for applying OCR and such. Dithering is not a good technique for converting when OCR is used.
The threshold is a color value that acts as a cut-off point for converting colors to black and white. All colors greater than the value map to white, and all colors less than or equal to the value side map to black.
The algorithm weights the RGB values using standard intensity calculations for converting color to gray-scale.
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.