ij.process
Class BinaryProcessor

java.lang.Object
  extended by ij.process.ImageProcessor
      extended by ij.process.ByteProcessor
          extended by ij.process.BinaryProcessor

public class BinaryProcessor
extends ByteProcessor

This class processes binary images.


Field Summary
(package private) static int OUTLINE
           
 
Fields inherited from class ij.process.ByteProcessor
DILATE, ERODE, oldx, oldy, pixels, snapshotPixels
 
Fields inherited from class ij.process.ImageProcessor
ABS, ADD, AND, antialiasedText, baseCM, BLACK, BLACK_AND_WHITE_LUT, BLUR_MORE, bLUT1, bLUT2, boldFont, CENTER_JUSTIFY, clipXMax, clipXMin, clipYMax, clipYMin, cm, cm2, cTable, cx, cy, defaultColorModel, drawingColor, EXP, fgColor, FILL, FIND_EDGES, fmImage, font, fontMetrics, GAMMA, gLUT1, gLUT2, height, histogramMax, histogramMin, histogramSize, image, img, interpolate, inversionTested, INVERT, invertedLut, justification, LEFT_JUSTIFY, lineWidth, LOG, lutAnimation, lutUpdateMode, mask, MAX, MAXIMUM, maxThreshold, MEDIAN_FILTER, MIN, MINIMUM, minThreshold, MULT, newPixels, NO_LUT_UPDATE, NO_THRESHOLD, OR, OVER_UNDER_LUT, progressBar, raster, RED_LUT, RIGHT_JUSTIFY, rLUT1, rLUT2, roiHeight, roiWidth, roiX, roiY, sampleModel, snapshotCopyMode, snapshotHeight, snapshotWidth, source, SQR, SQRT, width, WRONG_LENGTH, xMax, xMin, XOR, yMax, yMin
 
Constructor Summary
BinaryProcessor(ByteProcessor ip)
          Creates a BinaryProcessor from a ByteProcessor.
 
Method Summary
 void outline()
           
(package private)  void process(int type, int count)
           
 void skeletonize()
          Uses a lookup table to repeatably removes pixels from the edges of objects in a binary image, reducing them to single pixel wide skeletons.
(package private)  int thin(int pass, int[] table)
           
 
Methods inherited from class ij.process.ByteProcessor
applyLut, applyTable, convolve, convolve3x3, copyBits, createBufferedImage, createImage, createProcessor, crop, dilate, dilate, drawPixel, duplicate, erode, erode, fill, filter, filterEdge, flipVertical, get, get, getEdgePixel, getEdgePixel0, getf, getf, getHistogram, getHistogram, getInterpolatedPixel, getMax, getMin, getPixel, getPixels, getPixelsCopy, getPixelValue, getSnapshotPixels, medianFilter, noise, putPixel, putPixelValue, reset, reset, resetMinAndMax, resize, rotate, scale, set, set, setBackgroundValue, setColor, setf, setf, setFromFloatArrays, setFromFloatProcessors, setMinAndMax, setPixels, setPixels, setSnapshotPixels, setValue, snapshot, threshold, toFloat, toFloatArrays, toFloatProcessors
 
Methods inherited from class ij.process.ImageProcessor
abs, add, add, and, autoThreshold, convertToByte, convertToFloat, convertToRGB, convertToShort, drawDot, drawDot2, drawLine, drawOval, drawPolygon, drawRect, drawString, drawString, exp, fill, fillOval, fillPolygon, findEdges, flipHorizontal, gamma, getAutoThreshold, getAutoThreshold, getBestIndex, getCalibrationTable, getColorModel, getColumn, getCurrentColorModel, getDefaultColorModel, getFloatArray, getFontMetrics, getHeight, getHistogramMax, getHistogramMin, getHistogramSize, getIndexSampleModel, getIntArray, getInterpolate, getInterpolatedValue, getLine, getLutUpdateMode, getMask, getMaskArray, getMaxThreshold, getMinThreshold, getNChannels, getPixel, getPixelCount, getRoi, getRow, getStringWidth, getWidth, hideProgress, insert, invert, invertLut, isColorLut, isInvertedLut, isKillable, isPseudoColorLut, lineTo, log, makeDefaultColorModel, maskSizeError, max, maxValue, min, minValue, moveTo, multiply, or, putColumn, putPixel, putRow, resetBinaryThreshold, resetPixels, resetRoi, resetThreshold, resize, rotateLeft, rotateRight, setAntialiasedText, setCalibrationTable, setClipRect, setColor, setColorModel, setFloatArray, setFont, setHistogramRange, setHistogramSize, setIntArray, setInterpolate, setJustification, setLineWidth, setLutAnimation, setMask, setProgressBar, setRoi, setRoi, setRoi, setRoi, setSnapshotCopyMode, setThreshold, sharpen, showProgress, smooth, sqr, sqrt, toString, xor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

OUTLINE

static final int OUTLINE
See Also:
Constant Field Values
Constructor Detail

BinaryProcessor

public BinaryProcessor(ByteProcessor ip)
Creates a BinaryProcessor from a ByteProcessor. The ByteProcessor must contain a binary image (pixels values are either 0 or 255). Backgound is assumed to be white.

Method Detail

process

void process(int type,
             int count)

skeletonize

public void skeletonize()
Uses a lookup table to repeatably removes pixels from the edges of objects in a binary image, reducing them to single pixel wide skeletons. Based on an a thinning algorithm by by Zhang and Suen (CACM, March 1984, 236-239). There is an entry in the table for each of the 256 possible 3x3 neighborhood configurations. An entry of '1' means delete pixel on first pass, '2' means delete pixel on second pass, and '3' means delete on either pass. A graphical representation of the 256 neighborhoods indexed by the table is available at "http://rsb.info.nih.gov/ij/images/skeletonize-table.gif".

Overrides:
skeletonize in class ByteProcessor

thin

int thin(int pass,
         int[] table)

outline

public void outline()
Overrides:
outline in class ByteProcessor