Package org.esa.snap.rcp.magicwand
Class MagicWandInteractor
- java.lang.Object
-
- com.bc.ceres.swing.figure.AbstractInteractor
-
- com.bc.ceres.swing.figure.ViewportInteractor
-
- org.esa.snap.rcp.magicwand.MagicWandInteractor
-
- All Implemented Interfaces:
com.bc.ceres.swing.figure.Interactor
,KeyListener
,MouseListener
,MouseMotionListener
,EventListener
,MagicWandModel.Listener
public class MagicWandInteractor extends com.bc.ceres.swing.figure.ViewportInteractor implements MagicWandModel.Listener
An interactor that lets users create masks using a "magic wand". The mask comprises all pixels in the image that are "spectrally" close to the pixel that has been selected using the magic wand.- Since:
- BEAM 4.10
-
-
Constructor Summary
Constructors Constructor Description MagicWandInteractor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
activate()
void
deactivate()
MagicWandModel
getModel()
Window
getOptionsWindow()
boolean
isModelModified()
void
modelChanged(MagicWandModel model, boolean recomputeMask)
void
mouseClicked(MouseEvent event)
void
setModelModified(boolean modelModified)
void
setUndoContext(com.bc.ceres.swing.undo.UndoContext undoContext)
-
Methods inherited from class com.bc.ceres.swing.figure.ViewportInteractor
getModelToViewTransform, getViewport, getViewToModelTransform, toModelPoint, toModelPoint, toModelShape
-
Methods inherited from class com.bc.ceres.swing.figure.AbstractInteractor
addListener, cancelInteraction, getCursor, getListeners, isActive, isLeftMouseButtonDown, isMultiButton1Click, isSingleButton1Click, keyPressed, keyReleased, keyTyped, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, removeListener, startInteraction, stopInteraction
-
-
-
-
Method Detail
-
isModelModified
public boolean isModelModified()
-
setModelModified
public void setModelModified(boolean modelModified)
-
modelChanged
public void modelChanged(MagicWandModel model, boolean recomputeMask)
- Specified by:
modelChanged
in interfaceMagicWandModel.Listener
-
getOptionsWindow
public Window getOptionsWindow()
-
activate
public boolean activate()
- Specified by:
activate
in interfacecom.bc.ceres.swing.figure.Interactor
- Overrides:
activate
in classcom.bc.ceres.swing.figure.AbstractInteractor
-
deactivate
public void deactivate()
- Specified by:
deactivate
in interfacecom.bc.ceres.swing.figure.Interactor
- Overrides:
deactivate
in classcom.bc.ceres.swing.figure.AbstractInteractor
-
mouseClicked
public void mouseClicked(MouseEvent event)
- Specified by:
mouseClicked
in interfaceMouseListener
- Overrides:
mouseClicked
in classcom.bc.ceres.swing.figure.AbstractInteractor
-
getModel
public MagicWandModel getModel()
-
setUndoContext
public void setUndoContext(com.bc.ceres.swing.undo.UndoContext undoContext)
-
-