Package com.jhlabs.image
Class EdgeFilter
- java.lang.Object
-
- com.jhlabs.image.AbstractBufferedImageOp
-
- com.jhlabs.image.WholeImageFilter
-
- com.jhlabs.image.EdgeFilter
-
- All Implemented Interfaces:
java.awt.image.BufferedImageOp
,java.lang.Cloneable
public class EdgeFilter extends WholeImageFilter
An edge-detection filter.
-
-
Field Summary
Fields Modifier and Type Field Description static float[]
FREI_CHEN_H
static float[]
FREI_CHEN_V
protected float[]
hEdgeMatrix
static float[]
PREWITT_H
static float[]
PREWITT_V
static float
R2
static float[]
ROBERTS_H
static float[]
ROBERTS_V
static float[]
SOBEL_H
static float[]
SOBEL_V
protected float[]
vEdgeMatrix
-
Fields inherited from class com.jhlabs.image.WholeImageFilter
originalSpace, transformedSpace
-
-
Constructor Summary
Constructors Constructor Description EdgeFilter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected int[]
filterPixels(int width, int height, int[] inPixels, java.awt.Rectangle transformedSpace)
Actually filter the pixels.float[]
getHEdgeMatrix()
float[]
getVEdgeMatrix()
void
setHEdgeMatrix(float[] hEdgeMatrix)
void
setVEdgeMatrix(float[] vEdgeMatrix)
java.lang.String
toString()
-
Methods inherited from class com.jhlabs.image.WholeImageFilter
filter, transformSpace
-
Methods inherited from class com.jhlabs.image.AbstractBufferedImageOp
clone, createCompatibleDestImage, getBounds2D, getPoint2D, getRenderingHints, getRGB, setRGB, stringToColor
-
-
-
-
Field Detail
-
R2
public static final float R2
-
ROBERTS_V
public static final float[] ROBERTS_V
-
ROBERTS_H
public static final float[] ROBERTS_H
-
PREWITT_V
public static final float[] PREWITT_V
-
PREWITT_H
public static final float[] PREWITT_H
-
SOBEL_V
public static final float[] SOBEL_V
-
SOBEL_H
public static float[] SOBEL_H
-
FREI_CHEN_V
public static final float[] FREI_CHEN_V
-
FREI_CHEN_H
public static float[] FREI_CHEN_H
-
vEdgeMatrix
protected float[] vEdgeMatrix
-
hEdgeMatrix
protected float[] hEdgeMatrix
-
-
Method Detail
-
setVEdgeMatrix
public void setVEdgeMatrix(float[] vEdgeMatrix)
-
getVEdgeMatrix
public float[] getVEdgeMatrix()
-
setHEdgeMatrix
public void setHEdgeMatrix(float[] hEdgeMatrix)
-
getHEdgeMatrix
public float[] getHEdgeMatrix()
-
filterPixels
protected int[] filterPixels(int width, int height, int[] inPixels, java.awt.Rectangle transformedSpace)
Description copied from class:WholeImageFilter
Actually filter the pixels.- Specified by:
filterPixels
in classWholeImageFilter
- Parameters:
width
- the image widthheight
- the image heightinPixels
- the image pixelstransformedSpace
- the output bounds- Returns:
- the output pixels
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-