j2d.filters
Class DissolveFilter
java.lang.Object
j2d.filters.AbstractBufferedImageOp
j2d.filters.PointFilter
j2d.filters.DissolveFilter
- All Implemented Interfaces:
- ImageProcessorInterface, java.awt.image.BufferedImageOp, java.io.Serializable, java.lang.Cloneable
public class DissolveFilter
- extends PointFilter
A filter which "dissolves" an image by thresholding the alpha channel with random numbers.
- See Also:
- Serialized Form
Method Summary |
java.awt.image.BufferedImage |
filter(java.awt.image.BufferedImage src,
java.awt.image.BufferedImage dst)
|
int |
filterRGB(int x,
int y,
int rgb)
|
float |
getDensity()
|
float |
getSoftness()
|
java.awt.Image |
process(java.awt.Image image)
a basic garbage in, garbage out processor. |
void |
setDensity(float density)
Set the density of the image in the range 0..1. |
void |
setDestImage(java.awt.image.BufferedImage dst)
|
void |
setSoftness(float softness)
Set the density of the dissolve in the range 0..1. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
DissolveFilter
public DissolveFilter()
setDensity
public void setDensity(float density)
- Set the density of the image in the range 0..1.
*arg density The density
getDensity
public float getDensity()
setSoftness
public void setSoftness(float softness)
- Set the density of the dissolve in the range 0..1.
*arg softness The softness
getSoftness
public float getSoftness()
setDestImage
public void setDestImage(java.awt.image.BufferedImage dst)
process
public java.awt.Image process(java.awt.Image image)
- Description copied from interface:
ImageProcessorInterface
- a basic garbage in, garbage out processor.
- Specified by:
process
in interface ImageProcessorInterface
- Overrides:
process
in class AbstractBufferedImageOp
- Parameters:
image
- input image
- Returns:
- output image
filter
public java.awt.image.BufferedImage filter(java.awt.image.BufferedImage src,
java.awt.image.BufferedImage dst)
- Specified by:
filter
in interface java.awt.image.BufferedImageOp
- Overrides:
filter
in class PointFilter
filterRGB
public int filterRGB(int x,
int y,
int rgb)
- Specified by:
filterRGB
in class PointFilter
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object