public abstract class Binarizer extends Object
| Modifier | Constructor and Description | 
|---|---|
| protected  | Binarizer(LuminanceSource source) | 
| Modifier and Type | Method and Description | 
|---|---|
| abstract Binarizer | createBinarizer(LuminanceSource source)Creates a new object with the same type as this Binarizer implementation, but with pristine
 state. | 
| abstract BitMatrix | getBlackMatrix()Converts a 2D array of luminance data to 1 bit data. | 
| abstract BitArray | getBlackRow(int y,
           BitArray row)Converts one row of luminance data to 1 bit data. | 
| int | getHeight() | 
| LuminanceSource | getLuminanceSource() | 
| int | getWidth() | 
protected Binarizer(LuminanceSource source)
public final LuminanceSource getLuminanceSource()
public abstract BitArray getBlackRow(int y, BitArray row) throws NotFoundException
y - The row to fetch, which must be in [0, bitmap height)row - An optional preallocated array. If null or too small, it will be ignored.
            If used, the Binarizer will call BitArray.clear(). Always use the returned object.NotFoundException - if row can't be binarizedpublic abstract BitMatrix getBlackMatrix() throws NotFoundException
NotFoundException - if image can't be binarized to make a matrixpublic abstract Binarizer createBinarizer(LuminanceSource source)
source - The LuminanceSource this Binarizer will operate on.public final int getWidth()
public final int getHeight()
Copyright © 2007–2019. All rights reserved.