Package isula.image.util
Class ClusteredPixel
java.lang.Object
isula.image.util.ClusteredPixel
-
Constructor Summary
ConstructorDescriptionClusteredPixel
(int coordinateForX, int coordinateForY, double[][] imageGraph, int cluster) Creates a new pixel and associates it to a Cluster. -
Method Summary
Modifier and TypeMethodDescriptionboolean
int
int
getNeighbourhood
(ClusteredPixel[] partition, double[][] imageGraph) Return a neighborhood in reference to a partition.int
int
int
hashCode()
void
setCluster
(int cluster) void
setGreyScaleValue
(int greyScaleValue) void
setxCoordinate
(int coordinateForX) void
setyCoordinate
(int coordinateForY) toString()
-
Constructor Details
-
ClusteredPixel
public ClusteredPixel(int coordinateForX, int coordinateForY, double[][] imageGraph, int cluster) Creates a new pixel and associates it to a Cluster.- Parameters:
coordinateForX
- X coordinate.coordinateForY
- Y coordinate.imageGraph
- Graph representing the image.cluster
- Assigned cluster.
-
-
Method Details
-
getxCoordinate
public int getxCoordinate() -
setxCoordinate
public void setxCoordinate(int coordinateForX) -
getyCoordinate
public int getyCoordinate() -
setyCoordinate
public void setyCoordinate(int coordinateForY) -
getGreyScaleValue
public int getGreyScaleValue() -
setGreyScaleValue
public void setGreyScaleValue(int greyScaleValue) -
getCluster
public int getCluster() -
setCluster
public void setCluster(int cluster) -
toString
-
getNeighbourhood
Return a neighborhood in reference to a partition.- Parameters:
partition
- Partition.imageGraph
- Graph of the image.- Returns:
- Neighbours of the current pixel.
-
equals
-
hashCode
public int hashCode()
-