|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jscience.media.pictures.filters.Kernel
public class Kernel
A convolution kernel.
Field Summary | |
---|---|
int |
cols
DOCUMENT ME! |
static float[] |
EDGE_LAPLACE1
DOCUMENT ME! |
static float[] |
EDGE_LAPLACE2
DOCUMENT ME! |
static float[] |
FREI_CHEN_H
DOCUMENT ME! |
static float[] |
FREI_CHEN_V
DOCUMENT ME! |
float[] |
matrix
DOCUMENT ME! |
static float[] |
PREWITT_H
DOCUMENT ME! |
static float[] |
PREWITT_V
DOCUMENT ME! |
static float |
R2
DOCUMENT ME! |
static float[] |
ROBERTS_H
DOCUMENT ME! |
static float[] |
ROBERTS_V
DOCUMENT ME! |
int |
rows
DOCUMENT ME! |
static float[] |
SOBEL_H
DOCUMENT ME! |
static float[] |
SOBEL_V
DOCUMENT ME! |
int |
xCentre
DOCUMENT ME! |
int |
yCentre
DOCUMENT ME! |
Constructor Summary | |
---|---|
Kernel()
Construct a null kernel. |
|
Kernel(float[] matrix)
Construct a kernel with the given 3x3 matrix. |
|
Kernel(int rows,
int cols,
float[] matrix)
Construct a kernel with the given matrix. |
|
Kernel(int rows,
int cols,
int xCentre,
int yCentre,
float[] matrix)
Construct a kernel with the given matrix. |
Method Summary | |
---|---|
float[] |
getMatrix()
DOCUMENT ME! |
void |
normalize()
Normalize a convolution kernel. |
void |
setMatrix(float[] matrix)
Set the (3x3) convolution kernel. |
void |
setMatrix(int rows,
int cols,
float[] matrix)
Set the convolution kernel. |
void |
setMatrix(int rows,
int cols,
int xCentre,
int yCentre,
float[] matrix)
Set the convolution kernel. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final float R2
public static final float[] ROBERTS_V
public static final float[] ROBERTS_H
public static final float[] PREWITT_V
public static final float[] PREWITT_H
public static final float[] SOBEL_V
public static float[] SOBEL_H
public static final float[] FREI_CHEN_V
public static float[] FREI_CHEN_H
public static float[] EDGE_LAPLACE1
public static float[] EDGE_LAPLACE2
public float[] matrix
public int rows
public int cols
public int xCentre
public int yCentre
Constructor Detail |
---|
public Kernel()
public Kernel(float[] matrix)
matrix
- an array of 9 floats containing the kernelpublic Kernel(int rows, int cols, float[] matrix)
rows
- the number of rows in the kernelcols
- the number of columns in the kernelmatrix
- an array of rowscols floats containing the kernelpublic Kernel(int rows, int cols, int xCentre, int yCentre, float[] matrix)
rows
- the number of rows in the kernelcols
- the number of columns in the kernelxCentre
- the centre of the kernel in the x directionyCentre
- the centre of the kernel in the y directionmatrix
- an array of rowscols floats containing the kernelMethod Detail |
---|
public void setMatrix(float[] matrix)
matrix
- an array of 9 floats containing the kernelpublic void setMatrix(int rows, int cols, float[] matrix)
rows
- the number of rows in the kernelcols
- the number of columns in the kernelmatrix
- an array of rowscols floats containing the kernelpublic void setMatrix(int rows, int cols, int xCentre, int yCentre, float[] matrix)
rows
- the number of rows in the kernelcols
- the number of columns in the kernelxCentre
- the centre of the kernel in the x directionyCentre
- the centre of the kernel in the y directionmatrix
- an array of rowscols floats containing the kernelpublic float[] getMatrix()
public void normalize()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |