Changeset 6737


Ignore:
Timestamp:
07/27/10 14:51:32 (9 years ago)
Author:
curtis
Message:

Fix errors with array allocation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/components/common/src/loci/common/DataTools.java

    r6736 r6737  
    618618    } 
    619619    else if (bpp == 2) { 
    620       short[][] s = new short[width][height]; 
     620      short[][] s = new short[height][width]; 
    621621      for (int y=0; y<height; y++) { 
    622622        for (int x=0; x<width; x++) { 
     
    628628    } 
    629629    else if (bpp == 4 && fp) { 
    630       float[][] f = new float[width][height]; 
     630      float[][] f = new float[height][width]; 
    631631      for (int y=0; y<height; y++) { 
    632632        for (int x=0; x<width; x++) { 
     
    638638    } 
    639639    else if (bpp == 4) { 
    640       int[][] i = new int[width][height]; 
     640      int[][] i = new int[height][width]; 
    641641      for (int y=0; y<height; y++) { 
    642642        for (int x=0; x<width; x++) { 
     
    648648    } 
    649649    else if (bpp == 8 && fp) { 
    650       double[][] d = new double[width][height]; 
     650      double[][] d = new double[height][width]; 
    651651      for (int y=0; y<height; y++) { 
    652652        for (int x=0; x<width; x++) { 
     
    658658    } 
    659659    else if (bpp == 8) { 
    660       long[][] l = new long[width][height]; 
     660      long[][] l = new long[height][width]; 
    661661      for (int y=0; y<height; y++) { 
    662662        for (int x=0; x<width; x++) { 
Note: See TracChangeset for help on using the changeset viewer.