IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jan 26, 2009, 8:40:07 PM (17 years ago)
Author:
eugene
Message:

incorporating changes from 16bit mask upgrades (eam_branch_20081230)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppImage/src/ppImageReplaceBackground.c

    r20863 r21183  
    3030    // XXX Should this be options->maskValue or options->maskValue & ~options->satMask?
    3131    //     The latter will leave saturated pixels high
    32     psMaskType maskVal = options->maskValue;
     32    psImageMaskType maskVal = options->maskValue;
    3333
    3434    // user-defined masks to test for good/bad pixels (build from recipe list if not yet set)
    35     psMetadataAddU8(psphotRecipe, PS_LIST_TAIL, "MASK.PSPHOT", PS_META_REPLACE, "user-defined mask", maskVal);
     35    psMetadataAddImageMask(psphotRecipe, PS_LIST_TAIL, "MASK.PSPHOT", PS_META_REPLACE, "user-defined mask", maskVal);
    3636
    3737    // Since we are working on a chip-mosaicked image, there should only be a single cell and readout
     
    146146            if (!isfinite(value)) {
    147147                image->data.F32[y][x] = NAN;
    148                 mask->data.PS_TYPE_MASK_DATA[y][x] |= options->badMask;
     148                mask->data.PS_TYPE_IMAGE_MASK_DATA[y][x] |= options->badMask;
    149149            } else {
    150150                image->data.F32[y][x] -= value;
     
    157157    for (int y = 0; y < numRows; y++) {
    158158        for (int x = 0; x < numCols; x++) {
    159             if (mask && mask->data.PS_TYPE_MASK_DATA[y][x] & maskVal) {
     159            if (mask && mask->data.PS_TYPE_IMAGE_MASK_DATA[y][x] & maskVal) {
    160160                image->data.F32[y][x] = 0.0;
    161161            } else {
     
    163163                if (!isfinite(value)) {
    164164                    image->data.F32[y][x] = NAN;
    165                     mask->data.PS_TYPE_MASK_DATA[y][x] |= options->badMask;
     165                    mask->data.PS_TYPE_IMAGE_MASK_DATA[y][x] |= options->badMask;
    166166                } else {
    167167                    image->data.F32[y][x] -= value;
Note: See TracChangeset for help on using the changeset viewer.