Changeset 2915


Ignore:
Timestamp:
06/27/07 10:03:55 (12 years ago)
Author:
melissa
Message:

Added support for composite image stacks.

Location:
trunk/loci/plugins
Files:
1 added
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/loci/plugins/Importer.java

    r2860 r2915  
    697697      makeRGB(imp, r, r.getSizeC()); 
    698698    } 
    699     else if (mergeChannels && r.getSizeC() > 1 && r.getSizeC() < 4 && 
    700       imp.getStackSize() == r.getSizeC()) 
    701     { 
    702       // create a composite image - this feature is available starting in 
    703       // ImageJ 1.38n 
    704  
    705       if (IJ.versionLessThan("1.38n")) { 
    706         IJ.showMessage("Please upgrade to ImageJ 1.38n to use this feature."); 
    707       } 
    708       else { 
    709         // use reflection to construct CompositeImage, 
    710         // in case ImageJ version is too old 
    711         ReflectedUniverse ru = new ReflectedUniverse(); 
    712         try { 
    713           ru.exec("import ij.CompositeImage"); 
    714           ru.setVar("imp", imp); 
    715           ru.setVar("sizeC", r.getSizeC()); 
    716           imp = (ImagePlus) ru.exec("new CompositeImage(imp, sizeC)"); 
    717         } 
    718         catch (ReflectException exc) { 
    719           reportException(exc, options.isQuiet(), 
    720             "Sorry, there was a problem constructing the composite image"); 
    721           return; 
    722         } 
    723       } 
     699    else if (mergeChannels && r.getSizeC() > 1 && r.getSizeC() < 4) { 
     700      imp = new CustomImage(imp, r.getSizeC()); 
    724701    } 
    725702    else if (mergeChannels && r.getSizeC() >= 4) { 
Note: See TracChangeset for help on using the changeset viewer.