Perform a snap and display the results, if desired. Returns the raw
If live mode is currently on, then instead of performing a snap, the
most recent images from live mode will be returned immediately.
Otherwise, this method will call AcquisitionManager.snap() to perform the
shouldDisplay - If true, then the snapped images will be added to
the Snap/Live display's Datastore and displayed. Note that the
displayed images will be run through the current application data
processing pipeline (if any) prior to display. Consequently, there
is no guarantee that a Snap/Live display window will be open after
calling snap(), even if shouldDisplay is set to true. If you want
to know when the display is visible, call
getDislay().waitUntilVisible() after calling snap().
A list of acquired Images from the snap.
Returns whether live mode is on.
If live mode is on but suspended, this method returns true.
true if live mode is on.
default boolean getIsLiveModeOn()
void setLiveModeOn(boolean on)
Turns live mode on or off. This will post an
org.micromanager.events.LiveModeEvent on the global application event
on - If true, then live mode will be activated; otherwise it will
default void setLiveMode(boolean on)
void setSuspended(boolean shouldSuspend)
Temporarily halt live mode, or re-start it after a temporary halt. This
is useful for actions that cannot be performed while live mode is
running (such as changing many camera settings), so that live mode can
be re-started once the action is complete. Instead of calling
isLiveModeOn(), stopping it if necessary, and then re-starting it if
it was on, you can instead blindly do:
- do something that can't run when live mode is on;
and live mode will only be re-started if it was on to begin with.
Note that suspending live mode does not produce LiveModeEvents, as the
expectation is that live mode is only suspended for very brief periods.
shouldSuspend - If true, then live mode will be halted if it is
running. If false, and live mode was running when
setSuspended(true) was called, then live mode will be restarted.
Insert the provided image into the Datastore, causing it to be displayed
in any open Snap/Live DisplayWindows. If no displays are open or if the
image dimensions don't match those of the previously-displayed images,
then a new display will be created.
Return the DisplayWindow used for snap/live mode. May be null if that
display has been closed. Snap/live mode only "knows about" the display
it itself created -- thus, if the user duplicates that display and then
closes the original, you will get null when you call this method.
Likewise, the snap/live display window that the SnapLiveManager uses
is prone to being closed and re-created (e.g. when the parameters of
images generated by the Core are changed). Consequently, it is not
recommended that you keep references to the result of this method hanging
around in memory for long periods, as they may become out-of-date.