use of loci.plugins.in.DisplayHandler in project bioformats by openmicroscopy.
the class BF method openImagePlus.
public static ImagePlus[] openImagePlus(ImporterOptions options) throws FormatException, IOException {
ImportProcess process = new ImportProcess(options);
if (!process.execute())
return null;
DisplayHandler displayHandler = new DisplayHandler(process);
if (options != null && options.isShowOMEXML()) {
displayHandler.displayOMEXML();
}
ImagePlusReader reader = new ImagePlusReader(process);
ImagePlus[] imps = reader.openImagePlus();
if (options != null && options.showROIs()) {
displayHandler.displayROIs(imps);
}
if (!options.isVirtual()) {
process.getReader().close();
}
return imps;
}
Aggregations