org.shapelogic.imageprocessing
Interface SBPixelCompare

All Known Implementing Classes:
SBByteCompare, SBColorCompare, SBShortCompare, SBSimpleCompare

public interface SBPixelCompare

Interface for doing pixel compare. In order to handle both colors and gray scale have an interface that tells if 2 pixels are similar.

Author:
Sami Badawi

Method Summary
 void action(int index)
           
 int colorDistance(int color1, int color2)
           
 int getColorAsInt(int index)
           
 int getNumberOfPixels()
           
 void grabColorFromPixel(int startX, int startY)
           
 void init(ij.process.ImageProcessor ip)
           
 boolean isFarFromReferencColor()
           
 boolean isHandled(int index)
           
 boolean isModifying()
          Should pixels be modified.
 boolean newSimilar(int index)
           
 void setCurrentColor(int color)
           
 void setFarFromReferencColor(boolean farFromColor)
           
 void setHandled(int index)
           
 void setMaxDistance(int maxDistance)
           
 void setModifying(boolean input)
           
 boolean similar(int index)
          Test if a pixel at index is similar to the internal state
 

Method Detail

similar

boolean similar(int index)
Test if a pixel at index is similar to the internal state

Parameters:
index - to image

newSimilar

boolean newSimilar(int index)

action

void action(int index)

isHandled

boolean isHandled(int index)

setHandled

void setHandled(int index)

colorDistance

int colorDistance(int color1,
                  int color2)

init

void init(ij.process.ImageProcessor ip)
          throws java.lang.Exception
Throws:
java.lang.Exception

getNumberOfPixels

int getNumberOfPixels()

grabColorFromPixel

void grabColorFromPixel(int startX,
                        int startY)

isModifying

boolean isModifying()
Should pixels be modified.


setModifying

void setModifying(boolean input)

getColorAsInt

int getColorAsInt(int index)

setCurrentColor

void setCurrentColor(int color)

setMaxDistance

void setMaxDistance(int maxDistance)

isFarFromReferencColor

boolean isFarFromReferencColor()

setFarFromReferencColor

void setFarFromReferencColor(boolean farFromColor)


Copyright © 2009. All Rights Reserved.