|
I have a plugin that must open many Analyze images in succession, so there
is a loop that looks like :
for(int i=0; i<Nimages; i++)
{
ImagePlus imp = load(pathstring,filenamestring[i]);
//Do something with image
imp.close();
}
where the 'load' method is the one in 'Analyze_Reader'.
The problem is that the 'imp.close()' method does not really close the file
- just nulls the ImagePlus object. I know this because eventually, when
running loads of these loops together, the plugin crashes with the error
"Too Many Files Open".
Does anyone know how to close the Analyze file ?
Thanks
|