|
BIJ API |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--java.awt.Window | +--java.awt.Frame | +--ij.plugin.frame.PlugInFrame | +--VolumeJ.VJUserInterface
This class links the VJ classes to the ImageJ interface.
Copyright (c) 1999-2003, Michael Abramoff. All rights reserved.
Inner classes inherited from class java.awt.Frame |
java.awt.Frame.AccessibleAWTFrame |
Inner classes inherited from class java.awt.Window |
java.awt.Window.AccessibleAWTWindow |
Inner classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.AWTTreeLock |
Field Summary | |
protected java.awt.TextField[] |
aspectField
|
protected static float |
aspectx
|
protected static float |
aspecty
|
protected static float |
aspectz
|
protected java.awt.Choice |
axisChoice
|
protected java.awt.Checkbox |
backCheckbox
|
protected java.awt.TextField |
cineField
|
protected java.awt.TextField |
cineNField
|
protected java.awt.Choice |
classificationChoice
|
protected VJClassifier |
classifier
|
protected java.awt.TextArea |
classifierTextArea
|
protected java.awt.Checkbox |
cutoutCheckbox
|
protected java.awt.TextField[] |
cutoutField
|
protected static java.lang.String |
defaultDirectory
|
protected static float |
deviation
|
protected java.awt.Checkbox |
diskCheckbox
|
protected java.awt.Choice |
gradientChoice
|
protected int[] |
iList
|
protected java.awt.Choice |
indexChoice
|
protected boolean |
initializing
|
(package private) static java.awt.Frame |
instance
This window. |
protected java.awt.Choice |
interpolationChoice
|
protected static int |
ISOSURFACE
|
protected java.awt.TextField[] |
lightField
|
protected static float |
lightx
|
protected static float |
lighty
|
protected static float |
lightz
|
protected java.awt.Choice |
lutChoice
|
protected java.awt.Choice |
mappingChoice
|
protected static int |
number
|
protected static int |
RAYTRACE
|
protected java.awt.Button |
render
|
protected java.awt.Button |
renderCine
|
protected VJRenderer |
renderer
|
protected java.awt.Button |
renderExtra
|
protected java.awt.Button |
renderStereo
|
protected java.awt.Button |
renderStop
|
protected java.awt.TextField[] |
rotField
|
protected VJRenderView |
rs
|
protected static float |
scale
|
protected java.awt.TextField |
scaleField
|
protected VJShader |
shader
|
protected java.awt.Choice |
sourceChoice
|
protected java.awt.Checkbox |
testCheckbox
|
protected static float |
threshold
|
protected java.awt.TextField |
thresholdField
|
protected java.awt.Checkbox |
traceCheckbox
|
protected java.awt.TextField[] |
traceField
|
protected Volume |
v
|
protected static java.lang.String |
VERSION
|
protected static int |
VIEWSPACE
|
protected java.awt.TextField |
widthField
|
protected static float |
xrot
|
protected static float |
yrot
|
protected static float |
zrot
|
Fields inherited from class ij.plugin.frame.PlugInFrame |
title |
Fields inherited from class java.awt.Frame |
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, icon, ICONIFIED, mbManagement, menuBar, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, ownedWindows, resizable, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR |
Fields inherited from class java.awt.Window |
inputContext, OPENED, ownedWindowList, state, warningString, windowListener |
Fields inherited from class java.awt.Container |
component, containerListener, layoutMgr, listeningBoundsChildren, listeningChildren, ncomponents |
Fields inherited from class java.awt.Component |
accessibleContext, actionListenerK, adjustmentListenerK, appContext, background, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, componentListener, componentListenerK, componentOrientation, containerListenerK, cursor, dropTarget, enabled, eventMask, focusListener, focusListenerK, font, foreground, graphicsConfig, hasFocus, height, hierarchyBoundsListener, hierarchyBoundsListenerK, hierarchyListener, hierarchyListenerK, incRate, inputMethodListener, inputMethodListenerK, isInc, isPacked, itemListenerK, keyListener, keyListenerK, LEFT_ALIGNMENT, locale, LOCK, metrics, minSize, mouseListener, mouseListenerK, mouseMotionListener, mouseMotionListenerK, newEventsOnly, ownedWindowK, parent, peer, peerFont, popups, prefSize, RIGHT_ALIGNMENT, textListenerK, TOP_ALIGNMENT, valid, visible, width, windowClosingException, windowListenerK, x, y |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
VJUserInterface()
Open a new VJUserInterface. |
Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent e)
React to action e. |
protected void |
activateButtons(int listLength)
Activate the rendering buttons, depending on whether or not there is a stack, an image, or nothing available. |
protected java.awt.Choice |
createChoice(java.awt.Panel[] p,
java.lang.String s,
java.lang.String[] d,
int i)
Create a choice item, fill it with d strings and preselect item i. |
protected java.awt.Choice |
createChoice(java.awt.Panel p,
java.awt.GridBagConstraints constr,
java.awt.GridBagLayout layout,
java.lang.String s,
java.lang.String[] d,
int i)
Create a choice item, fill it with d strings and preselect item i. |
protected java.awt.Choice |
createChoice(java.awt.Panel p,
java.lang.String s,
java.lang.String[] d,
int i)
Create a choice item, fill it with d strings and preselect item i. |
protected java.awt.TextField |
createTextField(java.awt.Panel p,
java.awt.GridBagConstraints constr,
java.awt.GridBagLayout layout,
java.lang.String s,
java.lang.String d,
int i)
Create an entry item named s, with i characters in it. |
protected java.awt.TextField |
createTextField(java.awt.Panel p,
java.lang.String label,
java.lang.String defaultContents,
int nrChars)
Create a text field with default content "d" of length i (in characters), labeled by "s". |
protected java.awt.TextField[] |
createXYZField(java.awt.Panel[] p,
java.lang.String s,
java.lang.String[] d,
int i)
|
protected java.awt.TextField[] |
createXYZField(java.awt.Panel p,
java.lang.String[] d,
int i)
Create a series of text fields labeled with no label |
protected java.awt.TextField[] |
createXYZField(java.awt.Panel p,
java.lang.String s,
java.lang.String[] d,
int i)
|
(package private) static void |
error(java.lang.String s)
Writes a string to an error channel. |
protected float |
getFloatField(java.awt.TextField t)
Get the value of a Textfield as a float. |
protected int[] |
getImageWindows()
Get the ids of all open windows that are ImageJ stacks. |
protected int |
getIntField(java.awt.TextField t)
Get the value of a Textfield as an int. |
protected long |
getLongField(java.awt.TextField t)
Get a long from a TextField. |
boolean |
getLUT(VJClassifier classifier,
java.lang.String path)
Set the LUT of a classifier from an ImageJ or NIH LUT file. |
protected java.lang.String[] |
getWindowNames(int[] windows)
Get the names (by getTitle() method) from a list of windows. |
void |
itemStateChanged(java.awt.event.ItemEvent e)
React to action e. |
void |
keyPressed(java.awt.event.KeyEvent e)
|
void |
keyReleased(java.awt.event.KeyEvent e)
|
void |
keyTyped(java.awt.event.KeyEvent e)
React to action e. |
void |
lostOwnership(java.awt.datatransfer.Clipboard clipboard,
java.awt.datatransfer.Transferable contents)
|
protected void |
perform(java.awt.AWTEvent e)
React to Event e. |
(package private) static void |
progress(float d)
Writes a progress bar to a status channel. |
protected void |
propagateClassifier()
Propagate the change of classifier onto other dialog items and instances. |
protected VJClassifier |
resetClassifier(int index,
int lutIndex)
Create and setup a classifier according to the classifier number index (index only vali within VJUserInterface). |
protected VJRenderer |
resetRenderer(VJInterpolator interpolator,
VJClassifier classifier,
VJShader shader,
int algorithm,
boolean doCutouts,
int cutoutX,
int cutoutY,
int cutoutZ,
boolean doTrace,
int traceX,
int traceY)
Create a renderer for the shader, interpolator and renderer. |
protected VJShader |
resetShader(float lightx,
float lighty,
float lightz,
float aspectx,
float aspecty,
float aspectz)
Create a shader and light for the current light coordinates and aspect ratio. |
protected Volume |
resetVolume(ij.ImagePlus imp,
ij.ImagePlus impindex,
float aspectx,
float aspecty,
float aspectz)
Change the volume to be rendered, based on the stack in window imp. |
void |
showDialog()
Sets up the dialog window with all (dynamic) elements filled in. |
(package private) static void |
status(java.lang.String s)
Writes a string to a status channel. |
void |
windowClosing(java.awt.event.WindowEvent e)
VJUserInterface has been closed. |
(package private) static void |
write(java.lang.String s)
Writes a string to an output channel. |
(package private) static void |
write(java.lang.StringBuffer s)
Writes a string to an output channel. |
Methods inherited from class ij.plugin.frame.PlugInFrame |
close, focusGained, focusLost, run, windowActivated, windowClosed, windowDeactivated, windowDeiconified, windowIconified, windowOpened |
Methods inherited from class java.awt.Frame |
|
Methods inherited from class java.awt.Window |
addOwnedWindow, addWindowListener, adjustListeningChildren, applyResourceBundle, applyResourceBundle, connectOwnedWindow, dispatchEventImpl, dispose, eventEnabled, getFocusOwner, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getOwnedWindows, getOwner, getToolkit, getWarningString, hide, isActive, isShowing, nextFocus, pack, postEvent, postWindowEvent, preProcessKeyEvent, processEvent, processWindowEvent, removeOwnedWindow, removeWindowListener, resetGC, setCursor, setFocusOwner, show, toBack, toFront, transferFocus |
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, addImpl, applyOrientation, checkGD, countComponents, createChildHierarchyEvents, createHierarchyEvents, deliverEvent, dispatchEventToSelf, doLayout, findComponentAt, findComponentAt, findComponentAt, getAccessibleAt, getAccessibleChild, getAccessibleChildrenCount, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents_NoClientCode, getComponents, getInsets, getLayout, getMaximumSize, getMinimumSize, getMouseEventTarget, getPreferredSize, getWindow, insets, invalidate, invalidateTree, isAncestorOf, layout, lightweightPaint, lightweightPrint, list, list, locate, minimumSize, numListening, paint, paintComponents, paintHeavyweightComponents, postsOldMouseEvents, preferredSize, print, printComponents, printHeavyweightComponents, processContainerEvent, proxyEnableEvents, proxyRequestFocus, remove, remove, removeAll, removeContainerListener, setFont, setLayout, update, validate, validateTree |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, areInputMethodsEnabled, bounds, checkImage, checkImage, checkWindowClosingException, coalesceEvents, contains, contains, createImage, createImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getAccessibleIndexInParent, getAccessibleStateSet, getBackground, getBounds, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont_NoClientCode, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getInputMethodRequests, getLocation, getLocation, getLocationOnScreen_NoTreeLock, getLocationOnScreen, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getSize, getSize, getToolkitImpl, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isEnabledImpl, isFocusTraversable, isLightweight, isOpaque, isRecursivelyVisible, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, size, toString, transferFocus |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.awt.MenuContainer |
getFont, postEvent |
Field Detail |
protected java.awt.Button render
protected java.awt.Button renderCine
protected java.awt.Button renderStereo
protected java.awt.Button renderStop
protected java.awt.Button renderExtra
protected java.awt.Choice gradientChoice
protected java.awt.Choice classificationChoice
protected java.awt.Choice axisChoice
protected java.awt.Choice sourceChoice
protected java.awt.Choice indexChoice
protected java.awt.Choice mappingChoice
protected java.awt.Choice interpolationChoice
protected java.awt.Choice lutChoice
protected java.awt.Checkbox testCheckbox
protected java.awt.Checkbox cutoutCheckbox
protected java.awt.Checkbox traceCheckbox
protected java.awt.Checkbox backCheckbox
protected java.awt.Checkbox diskCheckbox
protected java.awt.TextField[] rotField
protected java.awt.TextField[] aspectField
protected java.awt.TextField[] lightField
protected java.awt.TextField[] cutoutField
protected java.awt.TextField[] traceField
protected java.awt.TextField cineField
protected java.awt.TextField cineNField
protected java.awt.TextField widthField
protected java.awt.TextField thresholdField
protected java.awt.TextField scaleField
protected java.awt.TextArea classifierTextArea
protected static java.lang.String defaultDirectory
protected int[] iList
protected static final java.lang.String VERSION
protected static final int RAYTRACE
protected static final int ISOSURFACE
protected static final int VIEWSPACE
protected VJRenderView rs
protected VJRenderer renderer
protected Volume v
protected VJShader shader
protected VJClassifier classifier
protected static int number
protected static float aspectx
protected static float aspecty
protected static float aspectz
protected static float scale
protected static float xrot
protected static float yrot
protected static float zrot
protected static float lightx
protected static float lighty
protected static float lightz
protected static float threshold
protected static float deviation
static java.awt.Frame instance
protected boolean initializing
Constructor Detail |
public VJUserInterface()
Method Detail |
public void windowClosing(java.awt.event.WindowEvent e)
windowClosing
in class ij.plugin.frame.PlugInFrame
e
- a WindowEvent containing the type of event that caused closing.public void showDialog()
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
e
- an ActionEvent.public void itemStateChanged(java.awt.event.ItemEvent e)
itemStateChanged
in interface java.awt.event.ItemListener
e
- an ItemEvent.public void keyTyped(java.awt.event.KeyEvent e)
keyTyped
in interface java.awt.event.KeyListener
e
- a KeyEvent.public void keyPressed(java.awt.event.KeyEvent e)
keyPressed
in interface java.awt.event.KeyListener
protected void activateButtons(int listLength)
listLength
- the number of stacks available.public void keyReleased(java.awt.event.KeyEvent e)
keyReleased
in interface java.awt.event.KeyListener
protected void perform(java.awt.AWTEvent e)
e
- an Event.protected VJRenderer resetRenderer(VJInterpolator interpolator, VJClassifier classifier, VJShader shader, int algorithm, boolean doCutouts, int cutoutX, int cutoutY, int cutoutZ, boolean doTrace, int traceX, int traceY)
interpolator
- a VJInterpolatorclassifier
- a VJClassifieralgorithm
- the type of renderer: RAYTRACE, ISOSURFACE or VIEWSPACE.protected Volume resetVolume(ij.ImagePlus imp, ij.ImagePlus impindex, float aspectx, float aspecty, float aspectz)
imp
- an Imageplus, which should contain a stack.impindex
- an ImagePlus, which can contain an index stack. If null no index is used.aspectx
- the aspect ratio x-dimension for the volume.aspecty
- the aspect ratio y-dimension for the volume.aspectz
- the aspect ratio z-dimension for the volume.protected VJShader resetShader(float lightx, float lighty, float lightz, float aspectx, float aspecty, float aspectz)
lightx
- the x-position of the light in viewspace.lighty
- the y-position of the light in viewspace.lightz
- the z-position of the light in viewspace.aspectx
- the aspect ratio of the volume along the x-axis.aspecty
- the aspect ratio of the volume along the y-axis.aspectz
- the aspect ratio of the volume along the z-axis.protected VJClassifier resetClassifier(int index, int lutIndex)
index
- the local index number of the classifier in VJClassifiers.lutIndex
- a flag indicating what LUT to use. 0 is built in LUT, 1 = user loadable LUT..protected void propagateClassifier()
public void lostOwnership(java.awt.datatransfer.Clipboard clipboard, java.awt.datatransfer.Transferable contents)
lostOwnership
in interface java.awt.datatransfer.ClipboardOwner
protected java.awt.TextField[] createXYZField(java.awt.Panel p, java.lang.String s, java.lang.String[] d, int i)
protected java.awt.TextField[] createXYZField(java.awt.Panel p, java.lang.String[] d, int i)
protected java.awt.TextField[] createXYZField(java.awt.Panel[] p, java.lang.String s, java.lang.String[] d, int i)
protected java.awt.Choice createChoice(java.awt.Panel[] p, java.lang.String s, java.lang.String[] d, int i)
protected java.awt.Choice createChoice(java.awt.Panel p, java.lang.String s, java.lang.String[] d, int i)
protected java.awt.Choice createChoice(java.awt.Panel p, java.awt.GridBagConstraints constr, java.awt.GridBagLayout layout, java.lang.String s, java.lang.String[] d, int i)
protected java.awt.TextField createTextField(java.awt.Panel p, java.awt.GridBagConstraints constr, java.awt.GridBagLayout layout, java.lang.String s, java.lang.String d, int i)
protected java.awt.TextField createTextField(java.awt.Panel p, java.lang.String label, java.lang.String defaultContents, int nrChars)
p
- the panel to which the text field will be added.label
- the label of the textfield.defaultContents
- the default contents of the text field.nrChars
- the length in characters of the text field.protected float getFloatField(java.awt.TextField t)
t
- a TextField.protected int getIntField(java.awt.TextField t)
t
- a TextField.protected long getLongField(java.awt.TextField t)
t
- the Textfield to parse.protected int[] getImageWindows()
protected java.lang.String[] getWindowNames(int[] windows)
windows
- an int array containing the ids of windows.static void progress(float d)
s
- the percentage that is filled.static void error(java.lang.String s)
s
- the String that will be output.static void write(java.lang.String s)
s
- the String that will be output.static void status(java.lang.String s)
s
- the String that will be shown in the status window.static void write(java.lang.StringBuffer s)
s
- the StringBuffer that will be output.public boolean getLUT(VJClassifier classifier, java.lang.String path)
classifier,
- a VJClassifier for which you want to read the LUT.path
- a filename to be read. Get from defaultpath, if defaultpath == "",
ask user for filename.
|
BIJ API |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |