net.grelf.grip
Interface AssociatedPane

All Known Implementing Classes:
Hist3D_Pane

public interface AssociatedPane

To enable mouse actions in an ImPane to affect another pane that implements this interface. For example, mouse hovering over an image causes indicators to move over a separate histogram image.


Method Summary
 void dragAction(int x, int y, int[] colour)
          Called when mouse is dragged.
 int getNBands()
          Return the number of channels in the image displayed in the associated pane.
 int getNBits()
          Return the number of bits per channel in the image displayed in the associated pane.
 void moveAction(int x, int y, int[] colour)
          Called when mouse is moved.
 void pressAction(int x, int y, int[] colour)
          Called when mouse is pressed.
 void releaseAction(int x, int y, int[] colour)
          Called when mouse is released.
 

Method Detail

dragAction

void dragAction(int x,
                int y,
                int[] colour)
Called when mouse is dragged.

Parameters:
x - The x coordinate of the mouse in the original pane.
y - The y coordinate of the mouse in the original pane.
colour - The channel values to be sent to the associated pane.

moveAction

void moveAction(int x,
                int y,
                int[] colour)
Called when mouse is moved.

Parameters:
x - The x coordinate of the mouse in the original pane.
y - The y coordinate of the mouse in the original pane.
colour - The channel values to be sent to the associated pane.

pressAction

void pressAction(int x,
                 int y,
                 int[] colour)
Called when mouse is pressed.

Parameters:
x - The x coordinate of the mouse in the original pane.
y - The y coordinate of the mouse in the original pane.
colour - The channel values to be sent to the associated pane.

releaseAction

void releaseAction(int x,
                   int y,
                   int[] colour)
Called when mouse is released.

Parameters:
x - The x coordinate of the mouse in the original pane.
y - The y coordinate of the mouse in the original pane.
colour - The channel values to be sent to the associated pane.

getNBands

int getNBands()
Return the number of channels in the image displayed in the associated pane. May be used by the original pane to determine the dimensionality of the colour array to be sent to the action methods.


getNBits

int getNBits()
Return the number of bits per channel in the image displayed in the associated pane. May be used by the original pane to determine the range of values in the colour array to be sent to the action methods.