IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 23, 2020, 3:29:09 PM (6 years ago)
Author:
tdeboer
Message:

added procedure to remove pixel NaNing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/pswarp/src/pswarpTransformReadout.c

    r35563 r41382  
    2727    int nGridX = psMetadataLookupS32(NULL, config->arguments, "GRID.NX"); ///< Number of grid points in x
    2828    int nGridY = psMetadataLookupS32(NULL, config->arguments, "GRID.NY"); ///< Number of grid points in y
     29    bool doApplyMaskNaN = psMetadataLookupBool(NULL, config->arguments, "APPLY.PIXELNAN"); ///NaN the pixels underneath masks
     30
    2931    psImageInterpolateMode interpolationMode = psMetadataLookupS32(NULL, config->arguments,
    3032                                                                   "INTERPOLATION.MODE"); ///< Mode for interp
     
    3739
    3840    // output mask bits
    39     psImageMaskType maskIn   = psMetadataLookupImageMask(&mdok, recipe, "MASK.INPUT");
     41    psImageMaskType maskIn   = 0 ;
     42    if(doApplyMaskNaN) {
     43      maskIn   = psMetadataLookupImageMask(&mdok, recipe, "MASK.INPUT");
     44      psAssert(mdok, "MASK.INPUT was not defined");
     45    }
    4046    psImageMaskType maskPoor = pmConfigMaskGet("CONV.POOR", config);
    4147    if (!maskPoor) {
     
    4652        maskBad  = pmConfigMaskGet("BAD.WARP", config);
    4753    }
    48     psAssert(mdok, "MASK.INPUT was not defined");
    4954
    5055    if (!input->covariance) {
Note: See TracChangeset for help on using the changeset viewer.