public class ThresholdFilter extends PointFilter
Modifier and Type | Field and Description |
---|---|
private int |
black |
private int |
lowerThreshold |
private int |
upperThreshold |
private int |
white |
canFilterIndexColorModel
Constructor and Description |
---|
ThresholdFilter()
Construct a ThresholdFilter.
|
ThresholdFilter(int t)
Construct a ThresholdFilter.
|
Modifier and Type | Method and Description |
---|---|
int |
filterRGB(int x,
int y,
int rgb) |
int |
getBlack()
Set the color to be used for pixels below the lower threshold.
|
int |
getLowerThreshold()
Get the lower threshold value.
|
int |
getUpperThreshold()
Get the upper threshold value.
|
int |
getWhite()
Get the color to be used for pixels above the upper threshold.
|
void |
setBlack(int black)
Set the color to be used for pixels below the lower threshold.
|
void |
setLowerThreshold(int lowerThreshold)
Set the lower threshold value.
|
void |
setUpperThreshold(int upperThreshold)
Set the upper threshold value.
|
void |
setWhite(int white)
Set the color to be used for pixels above the upper threshold.
|
String |
toString() |
filter, setDimensions
clone, createCompatibleDestImage, getBounds2D, getPoint2D, getRenderingHints, getRGB, setRGB
private int lowerThreshold
private int upperThreshold
private int white
private int black
public ThresholdFilter()
public ThresholdFilter(int t)
t
- the threshold valuepublic void setLowerThreshold(int lowerThreshold)
lowerThreshold
- the threshold valuegetLowerThreshold()
public int getLowerThreshold()
setLowerThreshold(int)
public void setUpperThreshold(int upperThreshold)
upperThreshold
- the threshold valuegetUpperThreshold()
public int getUpperThreshold()
setUpperThreshold(int)
public void setWhite(int white)
white
- the colorgetWhite()
public int getWhite()
setWhite(int)
public void setBlack(int black)
black
- the colorgetBlack()
public int getBlack()
setBlack(int)
public int filterRGB(int x, int y, int rgb)
filterRGB
in class PointFilter
WebARTS Library Licensed Under the GNU - General Public License. Other Libraries licensed under their respective Open Source Licenses