public final class RotationAdjustmentFilter extends java.lang.Object implements IBitmapFilter
Helper class to adjust the rotation angle.
Constructor and Description |
---|
RotationAdjustmentFilter()
Initializes a new instance of the
RotationAdjustmentFilter class. |
RotationAdjustmentFilter(int threshold)
Initializes a new instance of the
RotationAdjustmentFilter class. |
Modifier and Type | Method and Description |
---|---|
java.awt.image.BufferedImage |
apply(java.awt.image.BufferedImage javaImage)
Adjusts the bitmap.
|
java.awt.image.BufferedImage |
apply(java.awt.image.BufferedImage javaImage,
java.awt.Rectangle area) |
double |
detectAngle(Bitmap image)
Detects the angle.
|
public RotationAdjustmentFilter()
Initializes a new instance of the RotationAdjustmentFilter
class.
public RotationAdjustmentFilter(int threshold)
Initializes a new instance of the RotationAdjustmentFilter
class.
threshold
- The threshold.It should be a positive int and less than 255.public java.awt.image.BufferedImage apply(java.awt.image.BufferedImage javaImage)
Adjusts the bitmap.
apply
in interface IBitmapFilter
public java.awt.image.BufferedImage apply(java.awt.image.BufferedImage javaImage, java.awt.Rectangle area)
apply
in interface IBitmapFilter
public double detectAngle(Bitmap image)
Detects the angle.