IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 14355


Ignore:
Timestamp:
Jul 20, 2007, 3:09:05 PM (19 years ago)
Author:
Paul Price
Message:

Don't need to do calculations if the mask says it's bad. Check for bad values coming out of psStats.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/imcombine/pmReadoutCombine.c

    r14352 r14355  
    254254                }
    255255
     256                // Check mask
     257                psImage *roMask = readout->mask; // The mask image
     258                if (roMask && roMask->data.U8[yIn][xIn] & maskVal) {
     259                    maskData[r] = 1;
     260                    continue;
     261                }
     262
    256263                if (params->weights) {
    257264                    weightsData[r] = readout->weight->data.F32[yIn][xIn];
     
    266273                        weightsData[r] *= invScale->data.F32[r] * invScale->data.F32[r];
    267274                    }
    268                 }
    269 
    270                 // Check mask
    271                 psImage *roMask = readout->mask; // The mask image
    272                 if (roMask && roMask->data.U8[yIn][xIn] & maskVal) {
    273                     maskData[r] = 1;
    274                     continue;
    275275                }
    276276
     
    327327
    328328            outputImage[yOut][xOut] = psStatsGetValue(stats, params->combine);
     329            if (!isfinite(outputImage[yOut][xOut])) {
     330                outputMask[yOut][xOut] = params->blank;
     331            }
    329332            if (params->weights) {
    330333                float stdev = psStatsGetValue(stats, combineStdev);
Note: See TracChangeset for help on using the changeset viewer.