Changeset 7092


Ignore:
Timestamp:
10/19/10 17:24:35 (9 years ago)
Author:
melissa
Message:

Only populate Objective.NominalMagnification if the magnification is greater than 0.

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/4.2/components/bio-formats/src/loci/formats/in/ZeissZVIReader.java

    r7066 r7092  
    961961        } 
    962962        else if (key.startsWith("Objective Magnification")) { 
    963           store.setObjectiveNominalMagnification( 
    964               new PositiveInteger((int) Double.parseDouble(value)), 0, 0); 
     963          int magnification = (int) Double.parseDouble(value); 
     964          if (magnification > 0) { 
     965            store.setObjectiveNominalMagnification( 
     966              new PositiveInteger(magnification), 0, 0); 
     967          } 
    965968        } 
    966969        else if (key.startsWith("Objective ID")) { 
  • trunk/components/bio-formats/src/loci/formats/in/ZeissZVIReader.java

    r7066 r7092  
    961961        } 
    962962        else if (key.startsWith("Objective Magnification")) { 
    963           store.setObjectiveNominalMagnification( 
    964               new PositiveInteger((int) Double.parseDouble(value)), 0, 0); 
     963          int magnification = (int) Double.parseDouble(value); 
     964          if (magnification > 0) { 
     965            store.setObjectiveNominalMagnification( 
     966              new PositiveInteger(magnification), 0, 0); 
     967          } 
    965968        } 
    966969        else if (key.startsWith("Objective ID")) { 
Note: See TracChangeset for help on using the changeset viewer.