Changeset 27096 for trunk/pswarp/src/pswarpLoop.c
- Timestamp:
- Feb 25, 2010, 4:26:50 PM (16 years ago)
- File:
-
- 1 edited
-
trunk/pswarp/src/pswarpLoop.c (modified) (11 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/pswarp/src/pswarpLoop.c
r27063 r27096 84 84 psMetadata *recipe = psMetadataLookupPtr (&status, config->recipes, PSWARP_RECIPE); 85 85 if (!recipe) { 86 psError(PS PHOT_ERR_CONFIG, false, "missing recipe %s", PSWARP_RECIPE);86 psError(PSWARP_ERR_CONFIG, false, "missing recipe %s", PSWARP_RECIPE); 87 87 return false; 88 88 } 89 89 90 90 if (!pswarpSetMaskBits(config)) { 91 psError( PS_ERR_IO, false, "failed to set mask bits");91 psError(psErrorCodeLast(), false, "failed to set mask bits"); 92 92 return NULL; 93 93 } … … 111 111 112 112 if (astrom->camera != input->camera) { 113 psError(PS _ERR_UNKNOWN, true, "Input camera and astrometry camera do not match.");113 psError(PSWARP_ERR_DATA, true, "Input camera and astrometry camera do not match."); 114 114 return false; 115 115 } … … 211 211 if (bilevelAstrometry) { 212 212 if (!pmAstromReadBilevelMosaic(input->fpa, phu->header)) { 213 psError( PS_ERR_UNKNOWN, false, "Unable to read bilevel mosaic astrometry for input FPA.");213 psError(psErrorCodeLast(), false, "Unable to read bilevel mosaic astrometry for input FPA."); 214 214 psFree(view); 215 215 psFree(stats); … … 237 237 if (bilevelAstrometry) { 238 238 if (!pmAstromReadBilevelChip (chip, hdu->header)) { 239 psError( PS_ERR_UNKNOWN, false, "Unable to read bilevel chip astrometry for input FPA.");239 psError(psErrorCodeLast(), false, "Unable to read bilevel chip astrometry for input FPA."); 240 240 psFree(view); 241 241 psFree(stats); … … 245 245 // we use a default FPA pixel scale of 1.0 246 246 if (!pmAstromReadWCS (input->fpa, chip, hdu->header, 1.0)) { 247 psError( PS_ERR_UNKNOWN, false, "Unable to read WCS astrometry for input FPA.");247 psError(psErrorCodeLast(), false, "Unable to read WCS astrometry for input FPA."); 248 248 psFree(view); 249 249 psFree(stats); … … 312 312 313 313 if (!pswarpPixelsLit(output, stats, config)) { 314 psError( PS_ERR_UNKNOWN, false, "Unable to calculate pixel regions.");314 psError(psErrorCodeLast(), false, "Unable to calculate pixel regions."); 315 315 psFree(cells); 316 316 psFree(view); … … 349 349 350 350 if (!pmConceptsAverageCells(outCell, cells, NULL, NULL, false)) { 351 psError( PS_ERR_UNKNOWN, false, "Unable to average cell concepts.");351 psError(psErrorCodeLast(), false, "Unable to average cell concepts."); 352 352 psFree(stats); 353 353 psFree(cells); … … 361 361 362 362 if (!psMetadataCopy(outFPA->concepts, input->fpa->concepts)) { 363 psError( PS_ERR_UNKNOWN, false, "Unable to copy FPA concepts from input to output.");363 psError(psErrorCodeLast(), false, "Unable to copy FPA concepts from input to output."); 364 364 psFree(stats); 365 365 psFree(view); … … 388 388 pmHDU *skyHDU = pmHDUFromCell(cell); ///< HDU 389 389 if (!skyHDU) { 390 psError(PS _ERR_UNEXPECTED_NULL, false, "Unable to find skycell HDU.");390 psError(PSWARP_ERR_DATA, false, "Unable to find skycell HDU."); 391 391 psFree(view); 392 392 return false; … … 398 398 399 399 if (!pmAstromWriteWCS(hdu->header, outFPA, outChip, WCS_NONLIN_TOL)) { 400 psError( PS_ERR_UNKNOWN, false, "Unable to generate WCS header.");400 psError(psErrorCodeLast(), false, "Unable to generate WCS header."); 401 401 psFree(stats); 402 402 return false; … … 428 428 psArray *sources = psphotLoadPSFSources (config, view); 429 429 if (!sources) { 430 psError( PS_ERR_UNKNOWN, false, "No sources supplied to measure PSF");430 psError(psErrorCodeLast(), false, "No sources supplied to measure PSF"); 431 431 return false; 432 432 }
Note:
See TracChangeset
for help on using the changeset viewer.
