public class VariableBlurFilter extends AbstractBufferedImageOp
filterListener
Constructor and Description |
---|
VariableBlurFilter() |
Modifier and Type | Method and Description |
---|---|
void |
blur(int[] in,
int[] out,
int width,
int height,
int radius,
int pass) |
protected float |
blurRadiusAt(int x,
int y,
int width,
int height)
Override this to get a different blur radius at eahc point.
|
BufferedImage |
createCompatibleDestImage(BufferedImage src,
ColorModel dstCM) |
BufferedImage |
filter(BufferedImage src,
BufferedImage dst) |
BufferedImage |
getBlurMask()
Get the mask used to give the amount of blur at each point.
|
Rectangle2D |
getBounds2D(BufferedImage src) |
int |
getHRadius()
Get the horizontal size of the blur.
|
int |
getIterations()
Get the number of iterations the blur is performed.
|
Point2D |
getPoint2D(Point2D srcPt,
Point2D dstPt) |
boolean |
getPremultiplyAlpha()
Get whether to premultiply the alpha channel.
|
int |
getRadius()
Get the radius of the effect.
|
RenderingHints |
getRenderingHints() |
int |
getVRadius()
Get the vertical size of the blur.
|
void |
setBlurMask(BufferedImage blurMask)
Set the mask used to give the amount of blur at each point.
|
void |
setHRadius(int hRadius)
Set the horizontal size of the blur.
|
void |
setIterations(int iterations)
Set the number of iterations the blur is performed.
|
void |
setPremultiplyAlpha(boolean premultiplyAlpha)
Set whether to premultiply the alpha channel.
|
void |
setRadius(int radius)
Set the radius of the effect.
|
void |
setVRadius(int vRadius)
Set the vertical size of the blur.
|
String |
toString() |
clone, createCompatibleDestImage, filterDone, filterInitialize, filterProgress, filterStart, getMetaData, getRGB, setFilterListener, setRGB
public void setPremultiplyAlpha(boolean premultiplyAlpha)
premultiplyAlpha
- true to premultiply the alphagetPremultiplyAlpha()
public boolean getPremultiplyAlpha()
setPremultiplyAlpha(boolean)
public BufferedImage filter(BufferedImage src, BufferedImage dst)
filter
in interface BufferedImageOp
filter
in class AbstractBufferedImageOp
public BufferedImage createCompatibleDestImage(BufferedImage src, ColorModel dstCM)
createCompatibleDestImage
in interface BufferedImageOp
createCompatibleDestImage
in class AbstractBufferedImageOp
public Rectangle2D getBounds2D(BufferedImage src)
getBounds2D
in interface BufferedImageOp
getBounds2D
in class AbstractBufferedImageOp
public Point2D getPoint2D(Point2D srcPt, Point2D dstPt)
getPoint2D
in interface BufferedImageOp
getPoint2D
in class AbstractBufferedImageOp
public RenderingHints getRenderingHints()
getRenderingHints
in interface BufferedImageOp
getRenderingHints
in class AbstractBufferedImageOp
public void blur(int[] in, int[] out, int width, int height, int radius, int pass)
protected float blurRadiusAt(int x, int y, int width, int height)
x
- the x coordinatey
- the y coordinatewidth
- the width of the imageheight
- the height of the imagepublic void setHRadius(int hRadius)
hRadius
- the radius of the blur in the horizontal directiongetHRadius()
public int getHRadius()
setHRadius(int)
public void setVRadius(int vRadius)
vRadius
- the radius of the blur in the vertical directiongetVRadius()
public int getVRadius()
setVRadius(int)
public void setRadius(int radius)
radius
- the radiusgetRadius()
public int getRadius()
setRadius(int)
public void setIterations(int iterations)
iterations
- the number of iterationsgetIterations()
public int getIterations()
setIterations(int)
public void setBlurMask(BufferedImage blurMask)
blurMask
- the maskgetBlurMask()
public BufferedImage getBlurMask()
setBlurMask(java.awt.image.BufferedImage)
Copyright © 2012-2013 Bambi Software Foundation. All Rights Reserved.