A list of properties that should be persisted when the app closes, and restored the next time it's launched.
A list of properties that should be persisted when the app closes, and restored the next time it's launched. A common example of a persistent is the zoom/magnification level of the viewer. Be sure to add any relevenant properties to this list in your Viewer subclasses!
Returns the XML representation of this viewer's properties, suitable for saving into a file.
Returns the XML representation of this viewer's properties, suitable for saving into a file.
Reset the visualization.
Reset the visualization. An optional operation; subclasses must override this method or else it does nothing.
Restore this object to the state described in the given XML node.
Restore this object to the state described in the given XML node.
Encode the state of this object into an XML node.
Encode the state of this object into an XML node.
Update the view with new data.
Update the view with new data. This method schedules a repaint of the view.
Update the view with new data.
Update the view with new data. This method schedules a repaint of the view.
The field or object that generated the data
argument
New field data that needs to be rendered by this viewer
Parses the XML tag produced by the propertiesTag
method and restores
any saved valued to this Viewer.
Parses the XML tag produced by the propertiesTag
method and restores
any saved valued to this Viewer.
Increase zoom level by zDelta
.
Increase zoom level by zDelta
.
Zoom increment.
Zoom increment. This value is added/subtracted to the current zoomLevel
when zooming in or out. At a zoomLevel of 1, the image is rendered suh
that a single scalar element maps to exactly 1x1 pixel. A zoomLevel > 1
magnifies the image by that factor; e.g. a zoomLevel of 3 renders the
image such that each scalar element maps to 3x3 pixels.
Decrease zoom level by zDelta
.
Decrease zoom level by zDelta
.
Controls how zDelta is applied to the current zoom level.
Controls how zDelta is applied to the current zoom level. In Additive, a delta is added to the current zoom level; in Multiplicative mode, the zoom level is multiplied by delta when zooming in, and by its reciprocal when zooming out.
Default zoom type is additive. If you change it to multiplicative, you should probably ensure that the default zDelta is something other than 1f, as multiplying by one probably won't do anything.
A viewer for ScalarFields that assumes that they're holding grayscale images. That is, the values in the ScalarField are in the range [0f, 1f], with values <= 0 to be represented as black, and values >= 1 as pure white.
The view presented can look quite similar to that of the ScalarMemoryView, but because this view makes assumptions about the possible range of values, it's potentially more performant.
Only accepts ScalarFields of 2 dimensions or lower.