Changeset 2641


Ignore:
Timestamp:
04/19/07 09:03:33 (13 years ago)
Author:
melissa
Message:

Fixed a few more readers to support >2GB files.

Location:
trunk/loci/formats/in
Files:
5 edited

Legend:

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

    r2616 r2641  
    9595 
    9696    long fileOff = ((Long) offsets.get(no)).longValue(); 
    97     in.seek((int) fileOff); 
     97    in.seek(fileOff); 
    9898 
    9999    int pad = bmpScanLineSize - core.sizeX[0]*(bmpBitsPerPixel / 8); 
     
    150150    while ((in.length() - in.getFilePointer()) > 4) { 
    151151      in.read(list); 
    152       in.seek((int) pos); 
     152      in.seek(pos); 
    153153      listString = new String(list); 
    154154 
     
    167167        fcc = readStringBytes(); 
    168168 
    169         in.seek((int) spos); 
     169        in.seek(spos); 
    170170        if (fcc.equals("hdrl")) { 
    171171          type = readStringBytes(); 
     
    200200 
    201201                if (spos + size <= in.length()) { 
    202                   in.seek((int) (spos + size)); 
     202                  in.seek(spos + size); 
    203203                } 
    204204              } 
     
    234234 
    235235                if (spos + size <= in.length()) { 
    236                   in.seek((int) (spos + size)); 
     236                  in.seek(spos + size); 
    237237                } 
    238238              } 
     
    309309                } 
    310310 
    311                 in.seek((int) (spos + size)); 
     311                in.seek(spos + size); 
    312312              } 
    313313            } 
     
    350350              fcc = readStringBytes(); 
    351351              if (!(type.equals("LIST") && fcc.equals("rec "))) { 
    352                 in.seek((int) spos); 
     352                in.seek(spos); 
    353353              } 
    354354 
  • trunk/loci/formats/in/AliconaReader.java

    r2616 r2641  
    7373    } 
    7474 
     75    long offset = textureOffset; 
     76 
    7577    for (int i=0; i<numBytes; i++) { 
    76       in.seek(textureOffset + (no * (core.sizeX[0] + pad)*core.sizeY[0]*(i+1))); 
     78      in.seek(offset + (no * (core.sizeX[0] + pad)*core.sizeY[0]*(i+1))); 
    7779      for (int j=0; j<core.sizeX[0] * core.sizeY[0]; j++) { 
    7880        buf[j*numBytes + i] = (byte) in.read(); 
  • trunk/loci/formats/in/BioRadReader.java

    r2616 r2641  
    9898    } 
    9999 
    100     int offset = no * core.sizeX[0] * core.sizeY[0] * (byteFormat ? 1 : 2); 
     100    long offset = no * core.sizeX[0] * core.sizeY[0] * (byteFormat ? 1 : 2); 
    101101    in.seek(offset + 76); 
    102102    in.read(buf); 
  • trunk/loci/formats/in/LIFReader.java

    r2616 r2641  
    102102    } 
    103103 
    104     int offset = ((Long) offsets.get(series)).intValue(); 
     104    long offset = ((Long) offsets.get(series)).longValue(); 
    105105    in.seek(offset + core.sizeX[series] * core.sizeY[series] * 
    106106      bytes * no * getRGBChannelCount()); 
  • trunk/loci/formats/in/SlidebookReader.java

    r2636 r2641  
    4242 
    4343  /** Offset to pixel data. */ 
    44   private int offset = 1792; 
     44  private long offset = 1792; 
    4545 
    4646  /** Number of bytes per pixel. */ 
Note: See TracChangeset for help on using the changeset viewer.