Changeset 7226
- Timestamp:
- May 25, 2006, 4:48:47 PM (20 years ago)
- File:
-
- 1 edited
-
trunk/psLib/src/fits/psFitsHeader.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/fits/psFitsHeader.c
r7224 r7226 7 7 * @author Robert DeSonia, MHPCC 8 8 * 9 * @version $Revision: 1. 8$ $Name: not supported by cvs2svn $10 * @date $Date: 2006-05-26 0 0:48:20$9 * @version $Revision: 1.9 $ $Name: not supported by cvs2svn $ 10 * @date $Date: 2006-05-26 02:48:47 $ 11 11 * 12 12 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 32 32 33 33 // List of FITS header keys that may be duplicated; NULL-terminated 34 static char *duplicateFitsKeys[] = {"COMMENT", "HIERARCH", "HISTORY", "",NULL};34 static char *duplicateFitsKeys[] = {"COMMENT", "HIERARCH", "HISTORY", NULL}; 35 35 36 36 // List of FITS header keys not to write (handled by cfitsio); NULL-terminated 37 // XXX: Need to add table-related keywords here. 38 static char *noWriteFitsKeys[] = {"SIMPLE", "BITPIX", "NAXIS", "NAXIS1", "NAXIS2", "NAXIS3", "EXTNAME", 39 "BSCALE", "BZERO", NULL}; 37 static char *noWriteFitsKeys[] = {"SIMPLE", "XTENSION", "BITPIX", "NAXIS", "EXTNAME", "BSCALE", "BZERO", 38 "TFIELDS", NULL}; 39 // List of the start of FITS header keys not to write (handled by cfitsio); NULL-terminated 40 static char *noWriteFitsKeyStarts[] = {"NAXIS", "TTYPE", "TFORM", NULL}; 40 41 41 42 psMetadata* psFitsReadHeader(psMetadata* out, … … 261 262 } 262 263 } 264 // Also block out TTYPEn, NAXISn, etc --- keywords that start with a certain sequence 265 for (int i = 0; noWriteFitsKeyStarts[i] && writeKey; i++) { 266 if (strncmp(item->name, noWriteFitsKeyStarts[i], strlen(noWriteFitsKeyStarts[i])) == 0) { 267 writeKey = false; 268 } 269 } 263 270 if (!writeKey) { 264 271 // Don't write it; skip to the next key
Note:
See TracChangeset
for help on using the changeset viewer.
