plugins.big.bigsnake3d
Class BIGSnake3D

java.lang.Object
  extended by icy.plugin.abstract_.Plugin
      extended by icy.plugin.abstract_.PluginActionable
          extended by plugins.big.bigsnake3d.BIGSnake3D
All Implemented Interfaces:
icy.gui.main.ActiveSequenceListener, icy.gui.main.ActiveViewerListener, icy.gui.main.GlobalSequenceListener, icy.gui.main.GlobalViewerListener, icy.plugin.interface_.PluginImageAnalysis, java.awt.event.ActionListener, java.awt.event.KeyListener, java.lang.Runnable, java.util.EventListener, plugins.adufour.blocks.lang.Block

public class BIGSnake3D
extends icy.plugin.abstract_.PluginActionable
implements plugins.adufour.blocks.lang.Block, java.awt.event.ActionListener, icy.gui.main.ActiveSequenceListener, icy.gui.main.ActiveViewerListener, icy.gui.main.GlobalSequenceListener, icy.gui.main.GlobalViewerListener, java.awt.event.KeyListener

Main class of the Active Cells 3D plug-in.

Version:
February 11, 2015
Author:
Nicolas Chenouard (nicolas.chenouard@gmail.com), Ricard Delgado-Gonzalo (ricard.delgado@gmail.com), Emrah Bostan (emrah.bostan@gmail.com), Clement Marti (clement.marti@centraliens.net)

Constructor Summary
BIGSnake3D()
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
           
 void activateSnake(SnakeKeeper keeper)
          Makes a particular snake active and responsive to interaction.
 void activeSequenceChanged(icy.sequence.SequenceEvent event)
          Gets an event when a Sequence has changed.
 void activeViewerChanged(icy.gui.viewer.ViewerEvent event)
          Gets an event when a Viewer has changed.
 void declareInput(plugins.adufour.blocks.util.VarList inputMap)
          Declares the input parameters of the block.
 void declareOutput(plugins.adufour.blocks.util.VarList outputMap)
          Declares the output parameters of the block.
 boolean isActiveSnake(SnakeKeeper keeper)
          Returns true if SnakeKeeper passed is the active one.
 void keyPressed(java.awt.event.KeyEvent e)
          Interactions with respect to KeyEvent to detect the COPY and PASTE commands, and to translate the snake using the keyboard arrows.
 void keyReleased(java.awt.event.KeyEvent e)
          Gets an event when a key is released.
 void keyTyped(java.awt.event.KeyEvent e)
          Gets an event when a key is typed.
 void loadSnakeParametersFromInterface()
          Retrieves the snake parameters from the GUI and sets them to the active snake.
 void loadSnakesFromBinaryImage()
          Creates a new snake from a binary mask.
 void loadSnakesFromXML()
          Load the snakes from an XML file.
 void rasterizeActiveSnake()
           
 void run()
          Method executed when launching the plug-in.
 void saveSnakesToBinaryImage()
          Saves the snakes to a binary mask.
 void saveSnakesToXML()
          Saves the snakes to an XML file.
 void sequenceActivated(icy.sequence.Sequence sequence)
          Gets an event when a Sequence has been activated (focused).
 void sequenceClosed(icy.sequence.Sequence sequence)
          Gets an event when a Sequence has been closed.
 void sequenceDeactivated(icy.sequence.Sequence sequence)
          Gets an event when a Sequence has been deactivated (lost focus).
 void sequenceOpened(icy.sequence.Sequence sequence)
          Gets an event when a Sequence has been opened.
 void setDisplaySettings(DisplaySettings displaySettings)
           
 void terminatePlugin()
          Prepares the plug-in to be terminated.
 void viewerActivated(icy.gui.viewer.Viewer viewer)
          Gets an event when a Viewer has been activated (focused).
 void viewerClosed(icy.gui.viewer.Viewer viewer)
          Gets an event when a Viewer has been closed.
 void viewerDeactivated(icy.gui.viewer.Viewer viewer)
          Gets an event when a Viewer has been deactivated (lost focus).
 void viewerOpened(icy.gui.viewer.Viewer viewer)
          Gets an event when a Viewer has been opened.
 
Methods inherited from class icy.plugin.abstract_.PluginActionable
compute
 
Methods inherited from class icy.plugin.abstract_.Plugin
addIcyFrame, addSequence, getActiveImage, getActiveSequence, getActiveViewer, getDescriptor, getFocusedImage, getFocusedSequence, getFocusedViewer, getIconResource, getImageResource, getInstallFolder, getName, getOwnerClassName, getPlugin, getPreferences, getPreferencesRoot, getResource, getResourceAsStream, getResources, getSequences, isBundled, loadLibrary, removeSequence, report, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BIGSnake3D

public BIGSnake3D()
Method Detail

run

public void run()
Method executed when launching the plug-in.

Specified by:
run in interface java.lang.Runnable
Specified by:
run in interface plugins.adufour.blocks.lang.Block

terminatePlugin

public void terminatePlugin()
Prepares the plug-in to be terminated. All memory is freed, and auxiliary plug-ins are closed.


isActiveSnake

public boolean isActiveSnake(SnakeKeeper keeper)
Returns true if SnakeKeeper passed is the active one.


activateSnake

public void activateSnake(SnakeKeeper keeper)
Makes a particular snake active and responsive to interaction.


loadSnakeParametersFromInterface

public void loadSnakeParametersFromInterface()
Retrieves the snake parameters from the GUI and sets them to the active snake.


loadSnakesFromBinaryImage

public void loadSnakesFromBinaryImage()
Creates a new snake from a binary mask.


loadSnakesFromXML

public void loadSnakesFromXML()
Load the snakes from an XML file.


saveSnakesToBinaryImage

public void saveSnakesToBinaryImage()
Saves the snakes to a binary mask.


saveSnakesToXML

public void saveSnakesToXML()
Saves the snakes to an XML file.


rasterizeActiveSnake

public void rasterizeActiveSnake()

setDisplaySettings

public void setDisplaySettings(DisplaySettings displaySettings)

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Specified by:
actionPerformed in interface java.awt.event.ActionListener

activeSequenceChanged

public void activeSequenceChanged(icy.sequence.SequenceEvent event)
Gets an event when a Sequence has changed.

Specified by:
activeSequenceChanged in interface icy.gui.main.ActiveSequenceListener

sequenceActivated

public void sequenceActivated(icy.sequence.Sequence sequence)
Gets an event when a Sequence has been activated (focused).

Specified by:
sequenceActivated in interface icy.gui.main.ActiveSequenceListener

sequenceDeactivated

public void sequenceDeactivated(icy.sequence.Sequence sequence)
Gets an event when a Sequence has been deactivated (lost focus).

Specified by:
sequenceDeactivated in interface icy.gui.main.ActiveSequenceListener

activeViewerChanged

public void activeViewerChanged(icy.gui.viewer.ViewerEvent event)
Gets an event when a Viewer has changed.

Specified by:
activeViewerChanged in interface icy.gui.main.ActiveViewerListener

viewerActivated

public void viewerActivated(icy.gui.viewer.Viewer viewer)
Gets an event when a Viewer has been activated (focused).

Specified by:
viewerActivated in interface icy.gui.main.ActiveViewerListener

viewerDeactivated

public void viewerDeactivated(icy.gui.viewer.Viewer viewer)
Gets an event when a Viewer has been deactivated (lost focus).

Specified by:
viewerDeactivated in interface icy.gui.main.ActiveViewerListener

sequenceOpened

public void sequenceOpened(icy.sequence.Sequence sequence)
Gets an event when a Sequence has been opened.

Specified by:
sequenceOpened in interface icy.gui.main.GlobalSequenceListener

sequenceClosed

public void sequenceClosed(icy.sequence.Sequence sequence)
Gets an event when a Sequence has been closed.

Specified by:
sequenceClosed in interface icy.gui.main.GlobalSequenceListener

viewerOpened

public void viewerOpened(icy.gui.viewer.Viewer viewer)
Gets an event when a Viewer has been opened.

Specified by:
viewerOpened in interface icy.gui.main.GlobalViewerListener

viewerClosed

public void viewerClosed(icy.gui.viewer.Viewer viewer)
Gets an event when a Viewer has been closed.

Specified by:
viewerClosed in interface icy.gui.main.GlobalViewerListener

keyPressed

public void keyPressed(java.awt.event.KeyEvent e)
Interactions with respect to KeyEvent to detect the COPY and PASTE commands, and to translate the snake using the keyboard arrows.

Specified by:
keyPressed in interface java.awt.event.KeyListener

keyReleased

public void keyReleased(java.awt.event.KeyEvent e)
Gets an event when a key is released.

Specified by:
keyReleased in interface java.awt.event.KeyListener

keyTyped

public void keyTyped(java.awt.event.KeyEvent e)
Gets an event when a key is typed.

Specified by:
keyTyped in interface java.awt.event.KeyListener

declareInput

public void declareInput(plugins.adufour.blocks.util.VarList inputMap)
Declares the input parameters of the block.

Specified by:
declareInput in interface plugins.adufour.blocks.lang.Block

declareOutput

public void declareOutput(plugins.adufour.blocks.util.VarList outputMap)
Declares the output parameters of the block.

Specified by:
declareOutput in interface plugins.adufour.blocks.lang.Block