de.unihalle.informatik.MiToBo.enhance
Class TopHatContrastEnhancement

java.lang.Object
  extended by de.unihalle.informatik.Alida.operator.ALDOperator
      extended by de.unihalle.informatik.MiToBo.core.operator.MTBOperator
          extended by de.unihalle.informatik.MiToBo.enhance.TopHatContrastEnhancement
All Implemented Interfaces:
de.unihalle.informatik.Alida.datatypes.ALDConfigurationValidator, de.unihalle.informatik.Alida.operator.events.ALDOperatorExecutionProgressEventListener, EventListener

@ALDAOperator(genericExecutionMode=ALL,
              level=STANDARD,
              allowBatchMode=true)
@ALDMetaInfo(export=MANDATORY)
public class TopHatContrastEnhancement
extends MTBOperator

 
 This class enhances the contrast by top-hat operations, especially for gray
 value bright filed or DIC images. A white top-hat is added to the original
 image (enhance bright objects) and subsequent a black top-hat is subtracted
 (enhance dark objects).
 This approach works well for DIC images, maybe also for bright field or other
 illumination/contrast based images. Mask size of the structuring element
 should be small to preserve small structures, like neurites.
 
 NOTE: maybe the result image must be re-scaled, since output gray values can
       fall outside the dynamic range of the input image!
 
 Feel free to extend this class!
 
 
 The approach is adapted from:
 
 author = {Soille, Pierre},
 title = {Morphological Image Analysis: Principles
 and Applications},
 year = {2010},
 isbn = {9783642076961},
 edition = {2},
 pages = {126 -- 127},
 publisher = {Springer Berlin Heidelberg}.

Author:
Danny Misiak

Nested Class Summary
 
Nested classes/interfaces inherited from class de.unihalle.informatik.Alida.operator.ALDOperator
de.unihalle.informatik.Alida.operator.ALDOperator.HidingMode
 
Field Summary
 
Fields inherited from class de.unihalle.informatik.Alida.operator.ALDOperator
completeDAG, name, operatorExecutionEventlistenerList, portHashAccess, verbose, versionProvider
 
Constructor Summary
TopHatContrastEnhancement()
          Standard constructor.
TopHatContrastEnhancement(MTBImageByte _inputImage, Integer _wthMaskSize, Integer _bthMaskSize)
          Constructor to create a new IlluminationCorrection object.
 
Method Summary
 MTBImage getBthImage()
          Get black top-hat image.
 Integer getBthMaskSize()
          Get mask size of black top-hat.
 MTBImage getInputImage()
          Get low contrast input image.
 MTBImage getResultImage()
          Get contrast enhanced result image.
 MTBImage getWthImage()
          Get white top-hat image.
 Integer getWthMaskSize()
          Get mask size of white top-hat.
protected  void operate()
           
 void setBthMaskSize(Integer _bthMaskSize)
          Set mask size of black top-hat.
 void setInputImage(MTBImage _inputImage)
          Set low contrast input image.
 void setWthMaskSize(Integer _wthMaskSize)
          Set mask size of white top-hat.
 
Methods inherited from class de.unihalle.informatik.MiToBo.core.operator.MTBOperator
readResolve
 
Methods inherited from class de.unihalle.informatik.Alida.operator.ALDOperator
addOperatorExecutionProgressEventListener, fieldContained, fireOperatorExecutionProgressEvent, getALDPortHashAccessKey, getConstructionMode, getHidingMode, getInInoutNames, getInInoutNames, getInNames, getInOutNames, getMissingRequiredInputs, getName, getNumParameters, getOutInoutNames, getOutNames, getParameter, getParameterDescriptor, getParameterNames, getSupplementalNames, getVerbose, getVersion, handleOperatorExecutionProgressEvent, isConfigured, print, print, print, printInterface, printInterface, readHistory, reinitializeParameterDescriptors, removeOperatorExecutionProgressEventListener, runOp, runOp, runOp, setConstructionMode, setHidingMode, setName, setParameter, setVerbose, toStringVerbose, unconfiguredItems, validate, validateCustom, validateGeneric, writeHistory, writeHistory, writeHistory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TopHatContrastEnhancement

public TopHatContrastEnhancement()
                          throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException
Standard constructor.

Throws:
de.unihalle.informatik.Alida.exceptions.ALDOperatorException

TopHatContrastEnhancement

public TopHatContrastEnhancement(MTBImageByte _inputImage,
                                 Integer _wthMaskSize,
                                 Integer _bthMaskSize)
                          throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException
Constructor to create a new IlluminationCorrection object.

Parameters:
image - uneven illuminated input image
_wthMaskSize - mask size of white top-hat
_bthMaskSize - mask size of black top-hat
Throws:
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
Method Detail

getInputImage

public MTBImage getInputImage()
Get low contrast input image.


setInputImage

public void setInputImage(MTBImage _inputImage)
Set low contrast input image.


getWthMaskSize

public Integer getWthMaskSize()
Get mask size of white top-hat.


setWthMaskSize

public void setWthMaskSize(Integer _wthMaskSize)
Set mask size of white top-hat.


getBthMaskSize

public Integer getBthMaskSize()
Get mask size of black top-hat.


setBthMaskSize

public void setBthMaskSize(Integer _bthMaskSize)
Set mask size of black top-hat.


getWthImage

public MTBImage getWthImage()
Get white top-hat image.


getBthImage

public MTBImage getBthImage()
Get black top-hat image.


getResultImage

public MTBImage getResultImage()
Get contrast enhanced result image.


operate

protected void operate()
                throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException,
                       de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
Specified by:
operate in class de.unihalle.informatik.Alida.operator.ALDOperator
Throws:
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException


Copyright © 2010–2015 Martin Luther University Halle-Wittenberg. All rights reserved.