IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 12463


Ignore:
Timestamp:
Mar 15, 2007, 3:48:28 PM (19 years ago)
Author:
magnier
Message:

fixed mis-use of FLT_MIN (should have been -FLT_MAX)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/extras/pmKapaPlots.c

    r11939 r12463  
    77 *  @author EAM, IfA
    88 *
    9  *  @version $Revision: 1.8 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2007-02-20 19:27:40 $
     9 *  @version $Revision: 1.9 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2007-03-16 01:48:28 $
    1111 *
    1212 *  Copyright 2006 Institute for Astronomy, University of Hawaii
     
    6060
    6161    // set limits based on data values
    62     graphdata->xmin = FLT_MAX;
    63     graphdata->xmax = FLT_MIN;
    64     graphdata->ymin = FLT_MAX;
    65     graphdata->ymax = FLT_MIN;
     62    graphdata->xmin = +FLT_MAX;
     63    graphdata->xmax = -FLT_MAX;
     64    graphdata->ymin = +FLT_MAX;
     65    graphdata->ymax = +FLT_MAX;
    6666    for (int i = 0; i < xVec->n; i++) {
    6767        graphdata->xmin = PS_MIN (graphdata->xmin, xVec->data.F32[i]);
     
    109109
    110110    // set limits based on data values
    111     graphdata.xmin = FLT_MAX;
    112     graphdata.xmax = FLT_MIN;
    113     graphdata.ymin = FLT_MAX;
    114     graphdata.ymax = FLT_MIN;
     111    graphdata.xmin = +FLT_MAX;
     112    graphdata.xmax = -FLT_MAX;
     113    graphdata.ymin = +FLT_MAX;
     114    graphdata.ymax = -FLT_MAX;
    115115    for (int i = 0; i < xVec->n; i++) {
    116116        graphdata.xmin = PS_MIN (graphdata.xmin, xVec->data.F32[i]);
     
    149149
    150150    // set limits based on data values
    151     graphdata->xmin = FLT_MAX;
    152     graphdata->xmax = FLT_MIN;
    153     graphdata->ymin = FLT_MAX;
    154     graphdata->ymax = FLT_MIN;
    155     float zmin = FLT_MAX;
    156     float zmax = FLT_MIN;
     151    graphdata->xmin = +FLT_MAX;
     152    graphdata->xmax = -FLT_MAX;
     153    graphdata->ymin = +FLT_MAX;
     154    graphdata->ymax = -FLT_MAX;
     155    float zmin = +FLT_MAX;
     156    float zmax = -FLT_MAX;
    157157    for (int i = 0; i < xVec->n; i++) {
    158158        graphdata->xmin = PS_MIN (graphdata->xmin, xVec->data.F32[i]);
Note: See TracChangeset for help on using the changeset viewer.