Changeset 3246


Ignore:
Timestamp:
10/09/07 13:17:41 (12 years ago)
Author:
melissa
Message:

Fixed one last bug.

File:
1 edited

Legend:

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

    r3245 r3246  
    112112    FormatTools.checkBufferSize(this, buf.length); 
    113113 
    114     int ifd = ifdMap[currentSeries][no]; 
     114    int ifd = ifdMap[series][no]; 
    115115    int fileIndex = fileMap[currentSeries][no]; 
    116  
    117     /* debug */ System.out.println("plane " + no + " : ifd=" + ifd + 
    118       ", file=" + fileIndex); 
    119116 
    120117    in = new RandomAccessStream(used[fileIndex]); 
     
    335332          core.falseColor[currentSeries] = isFalseColor(); 
    336333 
    337           try { 
    338             if (fds != null && fds[currentSeries] != null) { 
    339               int x = (int) TiffTools.getImageWidth(fds[currentSeries][0]); 
    340               int y = (int) TiffTools.getImageLength(fds[currentSeries][0]); 
    341               if (x != core.sizeX[currentSeries]) { 
    342                 LogTools.println("Mismatched width: got " + 
    343                   core.sizeX[currentSeries] + ", expected " + x); 
    344                 core.sizeX[currentSeries] = x; 
    345               } 
    346               if (y != core.sizeY[currentSeries]) { 
    347                 LogTools.println("Mismatched height: got " + 
    348                   core.sizeY[currentSeries] + ", expected " + y); 
    349                 core.sizeY[currentSeries] = y; 
    350               } 
    351             } 
    352           } 
    353           catch (FormatException e) { } 
    354  
    355334          if (core.rgb[currentSeries] && core.indexed[currentSeries] && 
    356335            core.sizeC[currentSeries] == 3) 
     
    379358        } 
    380359        if (numIFDs != null) { 
    381           numIFDs[currentSeries] += fds[currentSeries].length; 
     360          numIFDs[currentSeries] += fds[currentFile].length; 
    382361        } 
    383362 
     
    399378        if (t == null || t.equals("")) t = "0"; 
    400379 
     380        try { 
     381          if (fds != null && fds[currentFile] != null) { 
     382            int f = Integer.parseInt(ifd); 
     383            int x = (int) TiffTools.getImageWidth(fds[currentFile][f]); 
     384            int y = (int) TiffTools.getImageLength(fds[currentFile][f]); 
     385            if (x != core.sizeX[currentSeries]) { 
     386              LogTools.println("Mismatched width: got " + 
     387                core.sizeX[currentSeries] + ", expected " + x); 
     388              core.sizeX[currentSeries] = x; 
     389            } 
     390            if (y != core.sizeY[currentSeries]) { 
     391              LogTools.println("Mismatched height: got " + 
     392                core.sizeY[currentSeries] + ", expected " + y); 
     393              core.sizeY[currentSeries] = y; 
     394            } 
     395          } 
     396        } 
     397        catch (FormatException e) { } 
     398 
    401399        int idx = FormatTools.getIndex(order, sizeZ, sizeC, sizeT, 
    402400          sizeZ * sizeC * sizeT, Integer.parseInt(z), Integer.parseInt(c), 
Note: See TracChangeset for help on using the changeset viewer.