Changeset 3276


Ignore:
Timestamp:
10/15/07 10:21:53 (12 years ago)
Author:
melissa
Message:
  • Fixed bug with "open each channel in new window" + "specify range".
  • Make sure pixel data offset is computed correctly for large LIF files.
Location:
trunk/loci
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/loci/formats/in/LIFReader.java

    r3239 r3276  
    9090 
    9191    long offset = ((Long) offsets.get(series)).longValue(); 
    92     in.seek(offset + core.sizeX[series] * core.sizeY[series] * no * 
     92    in.seek(offset + core.sizeX[series] * core.sizeY[series] * (long) no * 
    9393      FormatTools.getBytesPerPixel(getPixelType()) * getRGBChannelCount()); 
    94  
    9594    in.read(buf); 
    9695    return buf; 
  • trunk/loci/plugins/Importer.java

    r3275 r3276  
    576576          IFormatReader reader = first ? r : null; 
    577577          FileStitcher stitcher = first ? fs : null; 
     578          //new LociDataBrowser(reader, id, i, mergeChannels).run(); 
    578579          new LociDataBrowser(reader, stitcher, id, i, mergeChannels).run(); 
    579580          first = false; 
     
    605606    if (stack == null) return; 
    606607    if (!options.isMergeChannels() && options.isSplitWindows()) { 
    607       slice(stack, file, series, sizeZ, sizeC, sizeT, fi, r, fs, options); 
     608      slice(stack, file, series, zCount, cCount, tCount, fi, r, fs, options); 
    608609    } 
    609610    else { 
     
    652653    for (int i=0; i<c; i++) { 
    653654      if (range) { 
    654         for (int j=z; j<=t; j+=((t - z + 1) / is.getSize())) { 
    655           int s = (i*step) + (j - z)*c + 1; 
    656           if (s - 1 < is.getSize()) { 
    657             newStacks[i].addSlice(is.getSliceLabel(s), is.getProcessor(s)); 
    658           } 
     655        for (int j=0; j<z*t; j++) { 
     656          int ndx = j*step + 1; 
     657          newStacks[i].addSlice(is.getSliceLabel(ndx), is.getProcessor(ndx)); 
    659658        } 
    660659      } 
Note: See TracChangeset for help on using the changeset viewer.