com.pearsoneduc.ip.op
Class RegionLabelOp

java.lang.Object
  |
  +--com.pearsoneduc.ip.op.StandardGreyOp
        |
        +--com.pearsoneduc.ip.op.RegionLabelOp

public class RegionLabelOp
extends StandardGreyOp

Performs connected component labelling of an image. Each 4-connected or 8-connected region of pixels is given its own label.

Version:
1.0 [1999/08/26]
Author:
Nick Efford

Constructor Summary
RegionLabelOp(int c)
          Creates a RegionLabelOp with the specified connectivity.
 
Method Summary
 java.awt.image.BufferedImage filter(java.awt.image.BufferedImage src, java.awt.image.BufferedImage dest)
          Performs labelling of connected components in an image.
 
Methods inherited from class com.pearsoneduc.ip.op.StandardGreyOp
checkImage, createCompatibleDestImage, getBounds2D, getPoint2D, getRenderingHints
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RegionLabelOp

public RegionLabelOp(int c)
Creates a RegionLabelOp with the specified connectivity.
Parameters:
c - pixel connectivity (either 4 or 8)
Throws:
ImagingOpException - if connectivity is not 4 or 8.
Method Detail

filter

public java.awt.image.BufferedImage filter(java.awt.image.BufferedImage src,
                                           java.awt.image.BufferedImage dest)
Performs labelling of connected components in an image.
Parameters:
src - source image
dest - destination image, or null
Returns:
labelled image.
Throws:
ImagingOpException - if source image is not an 8-bit greyscale image.
Overrides:
filter in class StandardGreyOp