IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 25227


Ignore:
Timestamp:
Sep 1, 2009, 2:46:09 PM (17 years ago)
Author:
Paul Price
Message:

SAVE_AND_RESTORE_COMPRESSION can't be optional --- we can't apply the
compression parameters for one image to another (least of all can we
apply the compression parameters for a variance map to a covariance
matrix).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/magic/remove/src/streaksio.c

    r25226 r25227  
    12241224        if (SFILE_IS_IMAGE(in)) {
    12251225            // Turn off compression (code adapted from pmFPAWrite)
    1226 #ifdef SAVE_AND_RESTORE_COMPRESSION
    12271226            int bitpix = out->fits->options ? out->fits->options->bitpix : 0; // Desired bits per pixel
    12281227            psFitsCompression *compress = psFitsCompressionGet(out->fits); // Current compression options
    1229 #endif
    12301228            if (!psFitsSetCompression(out->fits, PS_FITS_COMPRESS_NONE, NULL, 0, 0, 0)) {
    12311229                psError(PM_ERR_UNKNOWN, false, "failed to turn off compression for extension %d\n", extnum);
    12321230                streaksExit("", PS_EXIT_UNKNOWN_ERROR);
    12331231            }
    1234 #ifdef SAVE_AND_RESTORE_COMPRESSION
    12351232            if (out->fits->options) {
    12361233                out->fits->options->bitpix = 0;
    12371234            }
    1238 #endif
    12391235            if (!psFitsWriteImage(out->fits, in->header, in->image, 0, in->extname)) {
    12401236                psError(PM_ERR_UNKNOWN, false, "failed to write image for extension %d\n", extnum);
    12411237                streaksExit("", PS_EXIT_UNKNOWN_ERROR);
    12421238            }
    1243 #ifdef SAVE_AND_RESTORE_COMPRESSION
    12441239            if (out->fits->options) {
    12451240                out->fits->options->bitpix = bitpix;
     
    12491244                streaksExit("", PS_EXIT_UNKNOWN_ERROR);
    12501245            }
    1251 #endif
    12521246        } else {
    12531247            copyTable(out, in, extnum);
Note: See TracChangeset for help on using the changeset viewer.