IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 1, 2006, 12:44:47 PM (20 years ago)
Author:
Paul Price
Message:

Adding pmFPAMaskWeight.h to psmodules.h, small changes to pmReadoutSetMask, removing pmMaskBadPixels from build (mostly achieved by simpler pmReadoutSetMask)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/camera/pmFPAMaskWeight.c

    r7017 r7275  
    1818        return false;
    1919    }
    20     float bad = psMetadataLookupF32(NULL, cell->concepts, "CELL.BAD"); // Bad level
     20    float bad = psMetadataLookupF32(&mdok, cell->concepts, "CELL.BAD"); // Bad level
    2121    if (!mdok || isnan(bad)) {
    2222        psError(PS_ERR_IO, true, "CELL.BAD is not set --- unable to set mask.\n");
    2323        return false;
    2424    }
     25    psTrace(__func__, 5, "Saturation: %f, bad: %f\n", saturation, bad);
    2526
    2627    psImage *image = readout->image;    // The image pixels
     
    3536    for (int i = 0; i < image->numRows; i++) {
    3637        for (int j = 0; j < image->numCols; j++) {
    37             if (image->data.F32[i][j] > saturation) {
     38            if (image->data.F32[i][j] >= saturation) {
    3839                mask->data.U8[i][j] |= PM_MASK_SAT;
    3940            }
    40             if (image->data.F32[i][j] < bad) {
     41            if (image->data.F32[i][j] <= bad) {
    4142                mask->data.U8[i][j] |= PM_MASK_BAD;
    4243            }
Note: See TracChangeset for help on using the changeset viewer.