setBatchMode true ???

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

setBatchMode true ???

nckrzan
Hi,

I have one question,

My Macro works with my problem using the particle analysis function. Of
course I use the setBatchMode true parameter, and therefore the Macro
works much faster ...

However after the analysis I want to display one window (image with the
results) on the screen - just for the "human eye" verification. ...

I thinks about something similar:

SelectWindow ...
Display
Wait (3000)

and came back to SetBatchMode true

My question - how to do it? Exist any procedure for displaying one windows
under setBatchMode true

Regards
Marcel Krzan
Reply | Threaded
Open this post in threaded view
|

Re: setBatchMode true ???

David Strachan
Hi  Marcel,

Use command setBatchMode(false);

It is described here in the documentation .... http://imagej.nih.gov/ij/developer/macro/functions.html#S

setBatchMode(arg)
 If arg is true, the interpreter enters batch mode and images are not displayed, allowing the macro to run up to 20 times faster. If arg is false, exits batch mode and displays the active image in a window. ImageJ exits batch mode when the macro terminates if there is no setBatchMode(false) call. Note that a macro should not call setBatchMode(true) more than once.
 
Set arg to "exit and display" to exit batch mode and display all open batch mode images. Here are five example batch mode macros: BatchModeTest, BatchMeasure, BatchSetScale, ReplaceRedWithMagenta.



Essentially just turn on Batch mode when you need speed and do not need to visualise, then just as easily turn batch mode back off when you do want to visualise.



Hope this helps

Regards

David Strachan


-----Original Message-----
From: ImageJ Interest Group [mailto:[hidden email]] On Behalf Of Marcel Krzan
Sent: 12 October 2011 20:00
To: [hidden email]
Subject: setBatchMode true ???

Hi,

I have one question,

My Macro works with my problem using the particle analysis function. Of course I use the setBatchMode true parameter, and therefore the Macro works much faster ...

However after the analysis I want to display one window (image with the
results) on the screen - just for the "human eye" verification. ...

I thinks about something similar:

SelectWindow ...
Display
Wait (3000)

and came back to SetBatchMode true

My question - how to do it? Exist any procedure for displaying one windows under setBatchMode true

Regards
Marcel Krzan