CenterForDigitalHumanities / SpectralRTI_Toolkit

Process Spectral RTI Images in ImageJ
GNU General Public License v3.0
1 stars 0 forks source link

Reduce warning for not enough hemisphere captures from 29 to 0 #70

Closed thanneken closed 6 years ago

thanneken commented 6 years ago

The macro was originally written for RTI only and static raking was added later. It is quite conceivable that one would have as few as one hemisphere captures and still want to do static raking. Basically this means the warning and fail if fewer than 30 hemisphere captures should be shifted down to requiring one. I just ran the macro with the following new lines:

while (listOfHemisphereCaptures.length < 1) { // changed from 29 to 1 6/1/2018
    showMessageWithCancel("Please Populate Hemisphere Captures","The software expects at least 1 image in HemisphereCaptures folder.\nPlease populate the folder and press Ok to continue, or cancel.");
    listOfHemisphereCaptures = getFileList(projectDirectory+"Captures-Hemisphere-Gamma"+File.separator);
}
thehabes commented 6 years ago

No problem, I will make the change.

thehabes commented 6 years ago
            while (listOfHemisphereCaptures.length < 1 && IJ.showMessageWithCancel("Please Populate Hemisphere Captures","The software expects at least 1 image in HemisphereCaptures folder.\nPlease populate the folder and press Ok to continue, or cancel.")){
                listOfHemisphereCaptures = getHemisphereCaptures(hemi_gamma_dir.toString());
            }
            if(listOfHemisphereCaptures.length < 1){
                IJ.error("There must be at least 1 image in the hemisphere caputres folder to continue.  Please populate for next time.");
                throw new Throwable("There must be at least 1 image in the hemisphere caputres folder to continue.  Please populate for next time.");
            }
thanneken commented 6 years ago

Confirmed on Linux