IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 26, 2010, 11:28:56 AM (16 years ago)
Author:
bills
Message:

don't call setMaskedtoNAN for imagecubes. Don't fail if we find one. streaksremove
excises them now

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/magic/remove/src/streaksrelease.c

    r26477 r27468  
    5050        strkGetMaskValues(sfiles);
    5151
    52         setMaskedToNAN(sfiles, sfiles->maskMask, true);
     52        if (!sfiles->inImage->imagecube) {
     53            setMaskedToNAN(sfiles, sfiles->maskMask, true);
     54        }
    5355
    5456        // write out the destreaked temporary images and the recovery images
     
    222224    if (sf->inImage->image) {
    223225        setupImageRefs(sf->outImage, sf->recImage, sf->inImage, sf->extnum, exciseAll);
    224     } else if (sf->inImage->imagecube) {
    225         // Image cubes should have been excised in the destreaking process
    226         streaksExit("unexpected imagecube found", PS_EXIT_CONFIG_ERROR);
    227226    }  else {
    228         return false;
     227        // image cubes are handled specially
    229228    }
    230229
     
    274273
    275274
     275// XXXX: why isn't this in streaksio.c ?? See also streakremove.c
    276276static void
    277277writeImages(streakFiles *sf, bool exciseImageCube)
     
    299299        }
    300300
    301         // borrow one of the images from the imagecube and set it to init value
    302         psImage *image = psArrayGet (sf->inImage->imagecube, 0);
    303         psMemIncrRefCounter(image);
    304         psImageInit(image, initValue);
    305         if (exciseImageCube) {
    306             sf->outImage->image = image;
    307             writeImage(sf->outImage, extname, sf->extnum);
    308         } else {
    309             // write zero valued image to reccovery
    310             if (sf->recImage) {
    311                 sf->recImage->image = image;
    312                 writeImage(sf->recImage, extname, sf->extnum);
    313             }
    314         }
    315301        // Assumption: there are no mask and weight images for video cells
    316302        return;
Note: See TracChangeset for help on using the changeset viewer.