public class NearestNeighborMatrix
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
NearestNeighborMatrix.Direction |
| Constructor and Description |
|---|
NearestNeighborMatrix()
Initialize a new instance of the NearestNeighborMatrix class.
|
NearestNeighborMatrix(int startIndex)
Initialize a new instance of the NearestNeighborMatrix class.
|
NearestNeighborMatrix(NearestNeighborMatrix.Direction direction)
Initialize a new instance of the NearestNeighborMatrix class.
|
NearestNeighborMatrix(NearestNeighborMatrix.Direction direction,
int startIndex)
Initialize a new instance of the NearestNeighborMatrix class.
|
| Modifier and Type | Method and Description |
|---|---|
NearestNeighborMatrix.Direction |
getDirection()
Get Direction.
|
IntPoint |
getPoint(int nearestNeighborIndex,
int width,
int height)
Get the point relative nearest neighbor matrix.
|
int |
getStartIndex()
Get Start index.
|
int[][] |
ProcessImage(FastBitmap fastBitmap)
Process image.
|
int[][] |
ProcessImage(FastBitmap fastBitmap,
java.util.ArrayList<IntPoint> boundary)
Process image.
|
void |
setDirection(NearestNeighborMatrix.Direction direction)
Set Direction.
|
void |
setStartIndex(int startIndex)
Set Start index.
|
public NearestNeighborMatrix()
public NearestNeighborMatrix(int startIndex)
startIndex - Start index.public NearestNeighborMatrix(NearestNeighborMatrix.Direction direction)
direction - Direction.public NearestNeighborMatrix(NearestNeighborMatrix.Direction direction, int startIndex)
direction - Direction.startIndex - Start index.public NearestNeighborMatrix.Direction getDirection()
public void setDirection(NearestNeighborMatrix.Direction direction)
direction - Direction.public int getStartIndex()
public void setStartIndex(int startIndex)
startIndex - Start index.public int[][] ProcessImage(FastBitmap fastBitmap)
fastBitmap - Image to be processed.public int[][] ProcessImage(FastBitmap fastBitmap, java.util.ArrayList<IntPoint> boundary)
fastBitmap - Image to be processed.boundary - List of points contains boundary of object.public IntPoint getPoint(int nearestNeighborIndex, int width, int height)
nearestNeighborIndex - Nearest Neighbor index.width - Width of the matrix.height - Height of the matrix.