Class SimplePixelTypeFinder

  extended by org.shapelogic.imageprocessing.SimplePixelTypeFinder
All Implemented Interfaces:
IPixelTypeFinder, PixelJumperByte

public class SimplePixelTypeFinder
extends java.lang.Object
implements IPixelTypeFinder

Find the type of a pixel. This is used in MaxDistanceVectorizer, and it is only using the neighboors.

Sami Badawi

Constructor Summary
SimplePixelTypeFinder(PixelJumperByte parent)
Method Summary
 PixelTypeCalculator findPointType(int pixelIndex, PixelTypeCalculator reusedPixelTypeCalculator)
          From the current point find direction.
 int[] getCyclePoints()
          What you need to add to the the index in the pixels array to get to the indexed point.
 int getMaxX()
 int getMaxY()
 int getMinX()
 int getMinY()
 byte[] getPixels()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public SimplePixelTypeFinder(PixelJumperByte parent)
Method Detail


public PixelTypeCalculator findPointType(int pixelIndex,
                                         PixelTypeCalculator reusedPixelTypeCalculator)
From the current point find direction. A problem with finding maximum is that the neighbor might not be known. Should the maximum only be calculated among unused? I think that if you have a V point and a junction If I already know a pixel should I do the calculation again?

Specified by:
findPointType in interface IPixelTypeFinder


public int[] getCyclePoints()
Description copied from interface: PixelJumperByte
What you need to add to the the index in the pixels array to get to the indexed point.

Specified by:
getCyclePoints in interface PixelJumperByte


public int getMaxX()
Specified by:
getMaxX in interface PixelJumperByte


public int getMaxY()
Specified by:
getMaxY in interface PixelJumperByte


public int getMinX()
Specified by:
getMinX in interface PixelJumperByte


public int getMinY()
Specified by:
getMinY in interface PixelJumperByte


public byte[] getPixels()
Specified by:
getPixels in interface PixelJumperByte

Copyright © 2009. All Rights Reserved.