ImageGear Professional for Windows ActiveX
ReduceToBitonal Method

Description:

Reduces an image from 24, 8, or 4 bpp to 1 bpp. Set Mode to specify how to get the threshold value.

Use the Threshold argument to set the threshold value for converting pixels to black or white. If the value, as calculated by one of the above reduction methods, is less than Threshold, the pixels will be set to black; if it is greater or equal to Threshold, the pixels will be set to white.

Syntax:

      ReduceToBitonal (ByVal pPage As IGPage, ByVal Mode As
enumIGBitonalReductModes, ByVal Threshold As Long, ByVal Weight1
As Long, ByVal Weight2 As Long, ByVal Weight3 As Long)

Parameters:

Name Description
pPage Reference to IGPage Object.
Mode Specifies what type of reduction to perform.
Threshold An integer value that specifies what pixel values will be changed to black, and which pixel values will be changed to white. Pixels with values greater than Threshold will be changed to white, and pixels that have values less than Threshold will be changed to black.
Weight1 These values are only used if Mode is set to IG_REDUCE_BITONAL_WEIGHTED. The range of values is 0 - 255. The default values are 255.
Weight2 The range of values is 0 - 255. The default values are 255.
Weight3 The range of values is 0 - 255. The default values are 255.

Return Value:

N/A

Bits Per Pixel:

4, 8, 24-bit input images; 1-bit output images

Sample:

Image Processing and Effects

 

 


©2016. Accusoft Corporation. All Rights Reserved.

Send Feedback