public class IJUtils extends Object
| Modifier and Type | Method and Description | 
|---|---|
static String[] | 
getOpenImageNames()
Return an array of String containing the name of all the currently open
 images. 
 | 
static ij.text.TextWindow[] | 
getTableWindows()
Iterates on the list of TextWindows, and keeps only the ones containing a
 non-null ResultsTable 
 | 
static int[] | 
parseLabelList(String string)
Extracts a list of integer labels from a string representation. 
 | 
static void | 
printImage(ij.process.ImageProcessor image)
Deprecated. 
 
use  
ImageUtils.print(ImageProcessor) instead | 
static String | 
showElapsedTime(String opName,
               double timeInMillis,
               ij.ImagePlus refImage)
Display elapsed time, converted into seconds, and computes number of
 processed elements per second. 
 | 
public static final String showElapsedTime(String opName, double timeInMillis, ij.ImagePlus refImage)
Example of use:
 // initialize processing 
 ImageStack image = IJ.getImage().getStack();
 Strel3D strel = CubeStrel.fromDiameter(5);
 
 // initialize timing 
 long t0 = System.currentTimeMillis();
 
 // start processing 
 ImageStack res = Morphology.dilation(image, strel);
 ImagePlus resPlus = new ImagePlus("Dilation Result", res);
 resPlus.show();
 
 // Display elapsed time
 long t1 = System.currentTimeMillis();
 IJUtils.showElapsedTime("dilation", t1 - t0, resPlus);
 opName - the name of the operation (algorithm, plugin...)timeInMillis - the elapsed time, in millisecondsrefImage - the image on which process was appliedpublic static final String[] getOpenImageNames()
public static final ij.text.TextWindow[] getTableWindows()
public static final int[] parseLabelList(String string)
string - the String containing labels, separated by commas or spaces.@Deprecated public static final void printImage(ij.process.ImageProcessor image)
ImageUtils.print(ImageProcessor) insteadimage - the image to display on the consoleCopyright © 2014–2023 INRA-IJPB Modeling and Digital Imaging lab. All rights reserved.