org.shapelogic.color
Class GrayEdgeArea
java.lang.Object
org.shapelogic.color.GrayAndVariance
org.shapelogic.color.GrayRange
org.shapelogic.color.GrayEdgeArea
- All Implemented Interfaces:
- ColorChannels, IColorAndVariance, IColorEdgeArea, IColorRange, HasArea, HasPixelArea, PixelHandler
public class GrayEdgeArea
- extends GrayRange
- implements IColorEdgeArea
GrayEdgeArea holds the information.
Should this have getter and setters?
Maybe start without.
Should this be split in color and gray?
I think that maybe it should.
- Author:
- Sami Badawi
Constructor Summary |
GrayEdgeArea(int x,
int y,
int startColor)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.shapelogic.imageutil.HasArea |
getArea |
LOW_CONTRAST_POS
public static final int LOW_CONTRAST_POS
- See Also:
- Constant Field Values
MEDIUM_CONTRAST_POS
public static final int MEDIUM_CONTRAST_POS
- See Also:
- Constant Field Values
HIGH_CONTRAST_POS
public static final int HIGH_CONTRAST_POS
- See Also:
- Constant Field Values
_borderCount
protected int[] _borderCount
_lastX
protected int _lastX
_lastY
protected int _lastY
GrayEdgeArea
public GrayEdgeArea(int x,
int y,
int startColor)
putPixel
public void putPixel(int x,
int y,
int color)
- Add the color for a given point (x,y).
The points needs to be added in sequence.
- Specified by:
putPixel
in interface PixelHandler
- Overrides:
putPixel
in class GrayRange
merge
public void merge(IColorAndVariance colorAndVariance)
- Specified by:
merge
in interface IColorAndVariance
- Overrides:
merge
in class GrayRange
getPixelArea
public PixelArea getPixelArea()
- Specified by:
getPixelArea
in interface HasPixelArea
- Overrides:
getPixelArea
in class GrayAndVariance
getAllContrastBorders
public int getAllContrastBorders()
- Specified by:
getAllContrastBorders
in interface IColorEdgeArea
getHighContrastBorders
public int getHighContrastBorders()
- Description copied from interface:
IColorEdgeArea
- Description of how much high contrast neighbor.
What would be a good measure for this.
Maybe the rate of borders that are high contrast to the one that are not.
So maybe have a 30 and 70 percentile contrast levels.
Or maybe I can just set the levels manually and do the count.
- Specified by:
getHighContrastBorders
in interface IColorEdgeArea
getMediumContrastBorders
public int getMediumContrastBorders()
- Specified by:
getMediumContrastBorders
in interface IColorEdgeArea
getLowContrastBorders
public int getLowContrastBorders()
- Specified by:
getLowContrastBorders
in interface IColorEdgeArea
addBorder
public void addBorder(int level)
- Count how many borders and the size of the border.
- Specified by:
addBorder
in interface IColorEdgeArea
- Parameters:
level
- low, medium or high
Copyright © 2008. All Rights Reserved.