IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Apr 29, 2009, 5:21:31 PM (17 years ago)
Author:
Paul Price
Message:

Deal with mask when binning.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppSkycell/src/ppSkycellLoop.c

    r24000 r24003  
    201201        psImageInit(image2, 0);
    202202
     203        psImage *mask1 = NULL, *mask2 = NULL; // Binned masks
     204        if (data->masksName) {
     205            mask1 = psImageAlloc(numCols1, numRows1, PS_TYPE_IMAGE_MASK);
     206            mask2 = psImageAlloc(numCols2, numRows2, PS_TYPE_IMAGE_MASK);
     207            psImageInit(mask1, 0xFF);
     208            psImageInit(mask2, 0xFF);
     209        }
     210
    203211        for (int j = 0; j < data->numInputs; j++) {
    204212            if (target->data.S32[j] != i) {
     
    256264            psImageOverlaySection(image1, bin1RO->image, xOffset1, yOffset1, "=");
    257265            psImageOverlaySection(image2, bin2RO->image, xOffset2, yOffset2, "=");
     266            if (data->masksName) {
     267                psImageOverlaySection(mask1, bin1RO->mask, xOffset1, yOffset1, "=");
     268                psImageOverlaySection(mask2, bin2RO->mask, xOffset2, yOffset2, "=");
     269            }
    258270
    259271            psFree(bin1RO);
     
    280292        ro1->image = image1;
    281293        ro2->image = image2;
     294        ro1->mask = mask1;
     295        ro2->mask = mask2;
    282296
    283297        ro1->data_exists = cell1->data_exists = cell1->parent->data_exists = true;
Note: See TracChangeset for help on using the changeset viewer.