adams.flow.transformer.pixelselector
Class RectangleOverlay

java.lang.Object
  extended by adams.core.ConsoleObject
      extended by adams.core.option.AbstractOptionHandler
          extended by adams.flow.transformer.pixelselector.AbstractPixelSelectorOverlay
              extended by adams.flow.transformer.pixelselector.AbstractSingleColorPixelSelectorOverlay
                  extended by adams.flow.transformer.pixelselector.RectangleOverlay
All Implemented Interfaces:
Debuggable, Destroyable, OptionHandler, ShallowCopySupporter<AbstractPixelSelectorOverlay>, SizeOfHandler, ImageOverlay, Serializable

public class RectangleOverlay
extends AbstractSingleColorPixelSelectorOverlay

Simply highlights the selected pixel

Some actions that generate data for this overlay:
adams.flow.transformer.pixelselector.TopLeftCorner
adams.flow.transformer.pixelselector.BottomRightCorner

Valid options are:

-D <int> (property: debugLevel)
    The greater the number the more additional info the scheme may output to 
    the console (0 = off).
    default: 0
    minimum: 0
 
-color <java.awt.Color> (property: color)
    The color to use for the overlay.
    default: #ff0000
 

Version:
$Revision: 4806 $
Author:
fracpete (fracpete at waikato dot ac dot nz)
See Also:
Serialized Form

Field Summary
 
Fields inherited from class adams.flow.transformer.pixelselector.AbstractSingleColorPixelSelectorOverlay
m_Color
 
Fields inherited from class adams.flow.transformer.pixelselector.AbstractPixelSelectorOverlay
m_Image
 
Fields inherited from class adams.core.option.AbstractOptionHandler
m_DebugLevel, m_OptionManager
 
Constructor Summary
RectangleOverlay()
           
 
Method Summary
protected  void doPaintOverlay(ImagePanel.PaintPanel panel, Graphics g)
          Paints the actual overlay over the image.
protected  Point getBottomRight()
          Returns the bottom-right corner to paint.
protected  String getGlobalInfo()
          Returns a string describing the object.
 Class[] getSuggestedActions()
          Returns some actions that generate data for this overlay.
protected  Point getTopLeft()
          Returns the top-left corner to paint.
 
Methods inherited from class adams.flow.transformer.pixelselector.AbstractSingleColorPixelSelectorOverlay
colorTipText, defineOptions, getColor, getDefaultColor, setColor
 
Methods inherited from class adams.flow.transformer.pixelselector.AbstractPixelSelectorOverlay
getImage, globalInfo, paintOverlay, setImage, shallowCopy, shallowCopy
 
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, debug, debug, debugLevelTipText, destroy, finishInit, getDebugLevel, getOptionManager, initialize, isDebugOn, newOptionManager, reset, setDebugLevel, toCommandLine, toString
 
Methods inherited from class adams.core.ConsoleObject
getDebugging, getSystemErr, getSystemOut, sizeOf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RectangleOverlay

public RectangleOverlay()
Method Detail

getGlobalInfo

protected String getGlobalInfo()
Returns a string describing the object.

Specified by:
getGlobalInfo in class AbstractPixelSelectorOverlay
Returns:
a description suitable for displaying in the gui

getSuggestedActions

public Class[] getSuggestedActions()
Returns some actions that generate data for this overlay.

Specified by:
getSuggestedActions in class AbstractPixelSelectorOverlay
Returns:
the actions

getTopLeft

protected Point getTopLeft()
Returns the top-left corner to paint.

Returns:
the location, null if none found

getBottomRight

protected Point getBottomRight()
Returns the bottom-right corner to paint.

Returns:
the location, null if none found

doPaintOverlay

protected void doPaintOverlay(ImagePanel.PaintPanel panel,
                              Graphics g)
Paints the actual overlay over the image.

Specified by:
doPaintOverlay in class AbstractPixelSelectorOverlay
Parameters:
panel - the panel this overlay is for
g - the graphics context


Copyright © 2012 University of Waikato, Hamilton, NZ. All Rights Reserved.