Class CannyEdges
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.flow.transformer.locateobjects.AbstractObjectLocator
-
- adams.flow.transformer.locateobjects.CannyEdges
-
- All Implemented Interfaces:
CleanUpHandler
,Destroyable
,GlobalInfoSupporter
,LoggingLevelHandler
,LoggingSupporter
,OptionHandler
,QuickInfoSupporter
,SizeOfHandler
,Stoppable
,Serializable
public class CannyEdges extends AbstractObjectLocator
Uses the BoofCV canny edges algorithm to locate objects.
-logging-level <OFF|SEVERE|WARNING|INFO|CONFIG|FINE|FINER|FINEST> (property: loggingLevel) The logging level for outputting errors and debugging output. default: WARNING
-blur-radius <int> (property: blurRadius) The blur radius. default: 2 minimum: 0
-threshold-low <float> (property: thresholdLow) The low threshold. default: 0.1 minimum: 0.0
-threshold-high <float> (property: thresholdHigh) The high threshold. default: 0.3 minimum: 0.0
- Version:
- $Revision: 78 $
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected int
m_BlurRadius
the blur radius to use.protected float
m_ThresholdHigh
the high threshold.protected float
m_ThresholdLow
the low threshold.-
Fields inherited from class adams.flow.transformer.locateobjects.AbstractObjectLocator
m_CanvasColor, m_CanvasHeight, m_CanvasWidth, m_CenterOnCanvas, m_Errors, m_Stopped, m_Warnings
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description CannyEdges()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
blurRadiusTipText()
Returns the tip text for this property.void
defineOptions()
Adds options to the internal list of options.protected LocatedObjects
doLocate(BufferedImage image, boolean annotateOnly)
Returns the input image as output.int
getBlurRadius()
Returns the blur radius.String
getQuickInfo()
Returns a quick info about the object, which can be displayed in the GUI.float
getThresholdHigh()
Returns the high threshold.float
getThresholdLow()
Returns the low threshold.String
globalInfo()
Returns a string describing the object.void
setBlurRadius(int value)
Sets the blur radius.void
setThresholdHigh(float value)
Sets the high threshold.void
setThresholdLow(float value)
Sets the low threshold.String
thresholdHighTipText()
Returns the tip text for this property.String
thresholdLowTipText()
Returns the tip text for this property.-
Methods inherited from class adams.flow.transformer.locateobjects.AbstractObjectLocator
addError, addWarning, annotate, canvasColorTipText, canvasHeightTipText, canvasWidthTipText, centerOnCanvas, centerOnCanvasTipText, check, cleanUp, destroy, getCanvasColor, getCanvasHeight, getCanvasWidth, getCenterOnCanvas, getDefaultCanvasColor, getDefaultCanvasHeight, getDefaultCanvasWidth, getDefaultCenterOnCanvas, getErrors, getWarnings, hasErrors, hasWarnings, initialize, locate, reset, setCanvasColor, setCanvasHeight, setCanvasWidth, setCenterOnCanvas, stopExecution
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, finishInit, getDefaultLoggingLevel, getOptionManager, loggingLevelTipText, newOptionManager, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfo
in interfaceGlobalInfoSupporter
- Specified by:
globalInfo
in classAbstractOptionHandler
- Returns:
- a description suitable for displaying in the gui
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptions
in interfaceOptionHandler
- Overrides:
defineOptions
in classAbstractObjectLocator
-
setBlurRadius
public void setBlurRadius(int value)
Sets the blur radius.- Parameters:
value
- the radius
-
getBlurRadius
public int getBlurRadius()
Returns the blur radius.- Returns:
- the radius
-
blurRadiusTipText
public String blurRadiusTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setThresholdLow
public void setThresholdLow(float value)
Sets the low threshold.- Parameters:
value
- the threshold
-
getThresholdLow
public float getThresholdLow()
Returns the low threshold.- Returns:
- the threshold
-
thresholdLowTipText
public String thresholdLowTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setThresholdHigh
public void setThresholdHigh(float value)
Sets the high threshold.- Parameters:
value
- the threshold
-
getThresholdHigh
public float getThresholdHigh()
Returns the high threshold.- Returns:
- the threshold
-
thresholdHighTipText
public String thresholdHighTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
getQuickInfo
public String getQuickInfo()
Returns a quick info about the object, which can be displayed in the GUI.- Specified by:
getQuickInfo
in interfaceQuickInfoSupporter
- Overrides:
getQuickInfo
in classAbstractObjectLocator
- Returns:
- null if no info available, otherwise short string
-
doLocate
protected LocatedObjects doLocate(BufferedImage image, boolean annotateOnly)
Returns the input image as output.- Specified by:
doLocate
in classAbstractObjectLocator
- Parameters:
image
- the image to processannotateOnly
- whether to annotate only- Returns:
- the containers of located objects
-
-