public class Neighborhood3x3
extends java.lang.Object
4 3 2 5 0 1 6 7 8
Modifier and Type | Field and Description |
---|---|
float |
center
Value of pixel located at the center of neighborhood, that is at (
x ,y ). |
float |
neighbor1
Value of pixel located at (
x+1 ,y ). |
float |
neighbor2
Value of pixel located at (
x+1 ,y-1 ). |
float |
neighbor3
Value of pixel located at (
x ,y-1 -1). |
float |
neighbor4
Value of pixel located at (
x -1,y -1). |
float |
neighbor5
Value of pixel located at (
x -1,y ). |
float |
neighbor6
Value of pixel located at (
x -1,y +1). |
float |
neighbor7
Value of pixel located at (
x ,y +1). |
float |
neighbor8
Value of pixel located at (
x +1,y +1). |
int |
offset |
int |
x |
int |
y |
Constructor and Description |
---|
Neighborhood3x3() |
Modifier and Type | Method and Description |
---|---|
float[] |
getNeighbors() |
public float center
x
,y
).public float neighbor1
x+1
,y
).public float neighbor2
x+1
,y-1
).public float neighbor3
x
,y-1
-1).public float neighbor4
x
-1,y
-1).public float neighbor5
x
-1,y
).public float neighbor6
x
-1,y
+1).public float neighbor7
x
,y
+1).public float neighbor8
x
+1,y
+1).public int x
public int y
public int offset