- Timestamp:
- Mar 17, 2009, 12:07:42 PM (17 years ago)
- Location:
- branches/cnb_branches/cnb_branch_20090301/psModules
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
src/camera/pmFPAWrite.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/cnb_branches/cnb_branch_20090301/psModules
-
Property svn:mergeinfo
set to (toggle deleted branches)
/branches/cnb_branches/cnb_branch_20090215/psModules merged eligible /trunk/psModules merged eligible /branches/cnb_branch_20090215/psModules 21495-22685 /branches/eam_branches/eam_branch_20090303/psModules 23158-23228
-
Property svn:mergeinfo
set to (toggle deleted branches)
-
branches/cnb_branches/cnb_branch_20090301/psModules/src/camera/pmFPAWrite.c
r22699 r23351 692 692 "Centre of covariance matrix in y", -yMinCovar); 693 693 694 // Turn off compression 695 int bitpix = fits->options ? fits->options->bitpix : 0; // Desired bits per pixel 696 psFitsCompression *compress = psFitsCompressionGet(fits); // Current compression options 697 if (!psFitsSetCompression(fits, PS_FITS_COMPRESS_NONE, NULL, 0, 0, 0)) { 698 psError(PS_ERR_UNKNOWN, false, "Unable to set FITS compression to NONE"); 699 psFree(extname); 700 psFree(header); 701 psFree(images); 702 psFree(compress); 703 return false; 704 } 705 if (fits->options) { 706 fits->options->bitpix = 0; 707 } 708 694 709 // Write images 695 710 if (!psFitsWriteImageCube(fits, header, images, extname)) { … … 699 714 psFree(header); 700 715 psFree(images); 716 if (fits->options) { 717 fits->options->bitpix = bitpix; 718 } 719 psFitsCompressionApply(fits, compress); 720 psFree(compress); 701 721 return 0; 702 722 } … … 704 724 psFree(header); 705 725 psFree(images); 726 727 // Restore compression 728 if (fits->options) { 729 fits->options->bitpix = bitpix; 730 } 731 if (!psFitsCompressionApply(fits, compress)) { 732 psError(PS_ERR_UNKNOWN, false, "Unable to set FITS compression to NONE"); 733 psFree(compress); 734 return false; 735 } 736 psFree(compress); 706 737 707 738 return true;
Note:
See TracChangeset
for help on using the changeset viewer.
