|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ViewerController
ViewerController extends BasicController and adds methods for multi-window environments.
Field Summary |
---|
Fields inherited from interface edu.uthscsa.ric.mango.BasicController |
---|
SLICE_DIRECTION_AXIAL, SLICE_DIRECTION_CORONAL, SLICE_DIRECTION_SAGITTAL |
Method Summary | |
---|---|
ViewerController |
addNewImage(ImageDimensions id,
VoxelDimensions vd,
ImageRange ir,
ByteBuffer[] buffers,
String orientation,
String name)
Adds new image. |
ViewerController |
addNewImage(ImageDimensions id,
VoxelDimensions vd,
String orientation,
String name)
Adds new image. |
void |
associatePluginWindow(String des,
JFrame win)
Associates a window generated by a plugin with the viewer. |
void |
closeAssociatedWindow(String des)
Closes a viewer-associated window. |
JButton |
createColorPickerButton(MangoColorSelectedListener listener,
boolean showUsedOnly)
Create a ROI color picker button. |
Point |
findCenterRelativeToScreen(Dimension size)
Returns location that will center window in current display. |
Point |
findCenterRelativeToViewer(Dimension size)
Returns location that will center window relative to viewer. |
Rectangle |
findCurrentDisplayBounds()
Returns bounds of display that viewer is currently within. |
Insets |
findCurrentDisplayInsets()
Returns insets of display that viewer is currently within. |
Dimension |
findCurrentDisplaySize()
Returns dimensions of display that viewer is currently within. |
Point |
findGoodPluginWindowLocation(Dimension size)
Returns an appropriate location for a new window. |
ViewerController[] |
getAllViewerControllers(boolean includeSelf)
Returns all currently open viewers. |
Atlas |
getAtlas(String atlasName)
Returns an atlas found by name. |
JFrame |
getFrame()
Returns viewer frame. |
File |
getLibDir()
Returns a directory to store library files. |
File |
getTempDir()
Returns a directory to store temporary data. |
void |
logToConsole(String str)
Write a message to the Mango console. |
void |
setViewerLocation(Point aPoint)
Sets the location of the viewer on the screen. |
void |
setViewerSize(int width)
Sets the width (pixels) of the viewer. |
void |
toFront()
Activates the viewer window. |
void |
updateAllViewers()
Updates the image and ROI slice data in all viewers. |
Method Detail |
---|
ViewerController addNewImage(ImageDimensions id, VoxelDimensions vd, ImageRange ir, ByteBuffer[] buffers, String orientation, String name)
id
- the ImageDimensionsvd
- the VoxelDimensionsir
- the ImageRangebuffers
- an array of FloatBuffers, one per timepointorientation
- the orientation stringname
- the name of the new image
ViewerController addNewImage(ImageDimensions id, VoxelDimensions vd, String orientation, String name)
id
- the ImageDimensionsvd
- the VoxelDimensionsorientation
- the orientation stringname
- the name of the new image
void associatePluginWindow(String des, JFrame win)
des
- the name of the windowwin
- the windowvoid closeAssociatedWindow(String des)
des
- the name of the window (as it would appear in the ToolBox window menu)JButton createColorPickerButton(MangoColorSelectedListener listener, boolean showUsedOnly)
listener
- callback after user selects colorshowUsedOnly
- true to only show used ROI colors in picker, false to show all colors
Point findCenterRelativeToScreen(Dimension size)
size
- the size of window
Point findCenterRelativeToViewer(Dimension size)
size
- the size of window
Rectangle findCurrentDisplayBounds()
Insets findCurrentDisplayInsets()
Dimension findCurrentDisplaySize()
Point findGoodPluginWindowLocation(Dimension size)
size
- new window size
ViewerController[] getAllViewerControllers(boolean includeSelf)
includeSelf
- include this ViewerController in the list
Atlas getAtlas(String atlasName)
atlasName
- name of the atlas
JFrame getFrame()
File getLibDir()
File getTempDir()
void logToConsole(String str)
str
- message to logvoid setViewerLocation(Point aPoint)
aPoint
- the location of the viewervoid setViewerSize(int width)
width
- number of pixelsvoid toFront()
void updateAllViewers()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |