IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Feb 26, 2008, 2:35:41 PM (18 years ago)
Author:
Paul Price
Message:

Trying to make the scaling of floating-point images a bit more robust. We don't want a write dying because it can't determine a suitable BSCALE and BZERO --- we need to save the write somehow, anyhow! So, if in doubt, use 1 and 0.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/fits/psFitsImage.c

    r16185 r16672  
    77 *  @author Robert DeSonia, MHPCC
    88 *
    9  *  @version $Revision: 1.24 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2008-01-23 03:08:03 $
     9 *  @version $Revision: 1.25 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2008-02-27 00:35:41 $
    1111 *
    1212 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    285285            // Choose an appropriate BSCALE and BZERO
    286286            if (!psFitsScaleDetermine(bscale, bzero, image, fits)) {
    287                 psError(PS_ERR_UNKNOWN, false, "Unable to determine BSCALE and BZERO for image.");
    288                 return NULL;
     287                // We can't have the write dying for this reason --- try to save it somehow!
     288                psWarning("Unable to determine BSCALE and BZERO for image --- setting to 1.0, 0.0");
     289                psErrorStackClear();
    289290            }
    290291        } else {
Note: See TracChangeset for help on using the changeset viewer.