public class GreyscaleConnectedComponentLabeler extends Object implements ImageAnalyser<FImage>
ConnectedComponent
s.
Internally we use a flood-fill approach to finding the
ConnectedComponent
s.
Constructor and Description |
---|
GreyscaleConnectedComponentLabeler() |
Modifier and Type | Method and Description |
---|---|
void |
analyseImage(FImage image)
Analyse an image.
|
List<ConnectedComponent> |
findComponents(FImage image)
Syntactic sugar for calling
analyseImage(FImage) followed by
getComponents() ; |
protected ConnectedComponent |
floodFill(FImage image,
Pixel start,
int[][] output,
int color) |
List<ConnectedComponent> |
getComponents() |
public GreyscaleConnectedComponentLabeler()
public List<ConnectedComponent> findComponents(FImage image)
analyseImage(FImage)
followed by
getComponents()
;image
- the image to extract components fromprotected ConnectedComponent floodFill(FImage image, Pixel start, int[][] output, int color)
public void analyseImage(FImage image)
ImageAnalyser
analyseImage
in interface ImageAnalyser<FImage>
image
- The image to process in place.public List<ConnectedComponent> getComponents()
analyseImage(FImage)
.