Changeset 14210
- Timestamp:
- Jul 13, 2007, 5:41:36 PM (19 years ago)
- Location:
- trunk/pswarp/src
- Files:
-
- 2 edited
-
pswarpLoop.c (modified) (5 diffs)
-
pswarpParseCamera.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/pswarp/src/pswarpLoop.c
r14007 r14210 1 1 # include "pswarp.h" 2 2 #include <ppStats.h> 3 4 #define WCS_NONLIN_TOL 0.001 // Non-linear tolerance for header WCS 3 5 4 6 // Loop over the inputs, warp them to the output skycell and then write out the output. … … 20 22 if (!astrom) { 21 23 astrom = input; 24 } 25 26 if (astrom->camera != input->camera) { 27 psError(PS_ERR_UNKNOWN, true, "Input camera and astrometry camera do not match."); 28 return false; 22 29 } 23 30 … … 89 96 // find the FPA phu 90 97 bool bilevelAstrometry = false; 91 pmHDU *phu = pmFPAviewThisPHU (view, astrom->fpa);98 pmHDU *phu = pmFPAviewThisPHU(view, astrom->fpa); 92 99 if (phu) { 93 char *ctype = psMetadataLookupStr (NULL, phu->header, "CTYPE1");100 char *ctype = psMetadataLookupStr(NULL, phu->header, "CTYPE1"); 94 101 if (ctype) { 95 102 bilevelAstrometry = !strcmp (&ctype[4], "-DIS"); … … 208 215 #endif 209 216 210 211 217 // Perform statistics on the output image 212 218 if (stats) { … … 216 222 } 217 223 218 pmHDU *hdu = out put->parent->parent->parent->hdu;// HDU for the output warped image224 pmHDU *hdu = outFPA->hdu; // HDU for the output warped image 219 225 if (!hdu->header) { 220 226 hdu->header = psMetadataAlloc(); 227 } 228 229 if (!pmAstromWriteWCS(hdu->header, outFPA, outChip, WCS_NONLIN_TOL)) { 230 psError(PS_ERR_UNKNOWN, false, "Unable to generate WCS header."); 231 psFree(stats); 232 return false; 221 233 } 222 234 -
trunk/pswarp/src/pswarpParseCamera.c
r13705 r14210 17 17 // the input image(s) are required arguments; they define the camera 18 18 status = false; 19 pmFPAfile *astrom = pmFPAfile BindFromArgs(&status, input, config, "PSWARP.ASTROM", "ASTROM");19 pmFPAfile *astrom = pmFPAfileDefineFromArgs(&status, config, "PSWARP.ASTROM", "ASTROM"); 20 20 if (!status) { 21 21 psError (PS_ERR_UNKNOWN, false, "failed to load find definition");
Note:
See TracChangeset
for help on using the changeset viewer.
