IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 28442


Ignore:
Timestamp:
Jun 23, 2010, 3:14:44 PM (16 years ago)
Author:
Paul Price
Message:

Make output of source list for warp optional.

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippconfig/recipes/pswarp.config

    r28043 r28442  
    1111INTERPOLATION.NUM       S32     1000            # Number of interpolation kernels to pre-calculate
    1212PSF                     BOOL    TRUE            # Measure PSF for warped image?
     13SOURCES                 BOOL    TRUE            # Write source list for warped image?
    1314
    1415MASK.STATS         BOOL    TRUE            # calculate mask statistics.
     
    2728        PSF     BOOL    FALSE
    2829END
     30
     31# Background restoration
     32BACKGROUND      METADATA
     33        SOURCES         BOOL    FALSE           # Write source list for warped image?
     34        PSF             BOOL    FALSE           # Measure PSF for warped image?
     35END
  • trunk/pswarp/src/pswarpParseCamera.c

    r27096 r28442  
    6161{
    6262    psAssert(config, "Require configuration");
     63    bool mdok;                          // Status of MD lookup
    6364
    6465    // The input image(s) is required: it defines the camera
     
    9495    psFree(skyConfig);
    9596
     97    psMetadata *recipe = psMetadataLookupPtr (&status, config->recipes, PSWARP_RECIPE);
     98    if (!recipe) {
     99        psError(PSWARP_ERR_CONFIG, false, "missing recipe %s", PSWARP_RECIPE);
     100        return false;
     101    }
     102
    96103    // The output skycell
    97104    pmFPAfile *output = pmFPAfileDefineSkycell(config, NULL, "PSWARP.OUTPUT");
     
    118125    }
    119126
    120     if (astrom) {
     127    if (astrom && psMetadataLookupBool(&mdok, recipe, "SOURCES")) {
    121128        pmFPAfile *outSources = pmFPAfileDefineSkycell(config, output->fpa, "PSWARP.OUTPUT.SOURCES");
    122129        if (!outSources) {
     
    127134    }
    128135
    129     psMetadata *recipe = psMetadataLookupPtr (&status, config->recipes, PSWARP_RECIPE);
    130     if (!recipe) {
    131         psError(PSWARP_ERR_CONFIG, false, "missing recipe %s", PSWARP_RECIPE);
    132         return false;
    133     }
    134 
    135     bool mdok;                          // Status of MD lookup
    136136    if (psMetadataLookupBool(&mdok, recipe, "PSF")) {
    137137        // This file, PSPHOT.INPUT, is just used as a carrier; output files (eg, PSPHOT.RESID) are defined by
  • trunk/pswarp/src/pswarpTransformReadout.c

    r28405 r28442  
    195195    psFree(interp);
    196196
    197     if (goodPixels > 0) {
     197    if (goodPixels > 0 && psMetadataLookupBool(&mdok, recipe, "SOURCES")) {
    198198        if (!pswarpTransformSources(output, input, config)) {
    199199            psError(psErrorCodeLast(), false, "Unable to interpolate image.");
Note: See TracChangeset for help on using the changeset viewer.