IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 5, 2009, 11:13:29 AM (17 years ago)
Author:
beaumont
Message:

Finished ppStack visualization. Unified the way in which visualizations are invoked, plotting windows are closed, etc

Location:
branches/cnb_branches/cnb_branch_20090215
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/cnb_branches/cnb_branch_20090215

  • branches/cnb_branches/cnb_branch_20090215/psLib/src/fits/psFitsImage.c

    r21183 r23197  
    77 *  @author Robert DeSonia, MHPCC
    88 *
    9  *  @version $Revision: 1.41 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2009-01-27 06:39:37 $
     9 *  @version $Revision: 1.42 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2009-02-19 03:15:40 $
    1111 *
    1212 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    266266    *floatType = PS_FITS_FLOAT_NONE;
    267267
    268     psFitsOptions *options = fits->options;
     268    psFitsOptions *options = fits->options; // Options for FITS writing
     269
     270    // Can't PLIO compress U16,U32,U64 directly, so convert them
     271    if (psFitsCompressionGetType(fits) == PS_FITS_COMPRESS_PLIO && (!options || options->bitpix == 0)) {
     272        switch (image->type.type) {
     273          case PS_TYPE_U16:
     274            return psImageCopy(NULL, image, PS_TYPE_S32);
     275          case PS_TYPE_U32:
     276            return psImageCopy(NULL, image, PS_TYPE_S64);
     277          case PS_TYPE_U64:
     278            // Conversion would result in numerical overflow
     279            psError(PS_ERR_IO, true, "Unable to compress U64 images");
     280            return NULL;
     281          default:
     282            // No action
     283            ;
     284        }
     285    }
     286
    269287    if (!options) {
    270288        return psMemIncrRefCounter((psImage*)image); // Casting away const
Note: See TracChangeset for help on using the changeset viewer.