IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 26, 2010, 9:18:39 AM (16 years ago)
Author:
Serge CHASTEL
Message:

Merging trunk in branch

Location:
branches/sc_branches/trunkTest
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/sc_branches/trunkTest

  • branches/sc_branches/trunkTest/psphot

    • Property svn:mergeinfo deleted
  • branches/sc_branches/trunkTest/psphot/src/psphotMagnitudes.c

    r28405 r29060  
    124124                return false;
    125125            }
    126 
    127 # if (0)
    128                 int nap = 0;
    129                 if (!psphotMagnitudes_Unthreaded (&nap, cells->data[j], psf, binning, backModel, backStdev, photMode, maskVal)) {
    130                     psError(PS_ERR_UNKNOWN, false, "Unable to guess model.");
    131                     return false;
    132                 }
    133                 Nap += nap;
    134 # endif
    135126        }
    136127
     
    186177        psImageKeepCircle (source->maskObj, source->peak->x, source->peak->y, source->apRadius, "OR", markVal);
    187178
    188         status = pmSourceMagnitudes (source, psf, photMode, maskVal); // maskVal includes markVal
     179        status = pmSourceMagnitudes (source, psf, photMode, maskVal, markVal);
    189180        if (status && isfinite(source->apMag)) Nap ++;
    190181
     
    268259            psArrayAdd(job->args, 1, cells->data[j]); // sources
    269260            PS_ARRAY_ADD_SCALAR(job->args, maskVal,  PS_TYPE_IMAGE_MASK);
     261            PS_ARRAY_ADD_SCALAR(job->args, markVal,  PS_TYPE_IMAGE_MASK);
    270262
    271263            if (!psThreadJobAddPending(job)) {
     
    304296    psArray *sources                = job->args->data[0];
    305297    psImageMaskType maskVal         = PS_SCALAR_VALUE(job->args->data[1],PS_TYPE_IMAGE_MASK_DATA);
     298    psImageMaskType markVal         = PS_SCALAR_VALUE(job->args->data[2],PS_TYPE_IMAGE_MASK_DATA);
    306299
    307300    for (int i = 0; i < sources->n; i++) {
     
    312305        if (model == NULL) {
    313306          psTrace ("psphot", 3, "fail mag : no valid model");
    314           source->pixWeight = NAN;
     307          source->pixWeightNotBad = NAN;
     308          source->pixWeightNotPoor = NAN;
    315309          continue;
    316310        }
    317311
    318         status = pmSourcePixelWeight (&source->pixWeight, model, source->maskObj, maskVal);
     312        status = pmSourcePixelWeight (&source->pixWeightNotBad, &source->pixWeightNotPoor, model, source->maskObj, maskVal, markVal);
    319313        if (!status) {
    320314          psTrace ("psphot", 3, "fail to measure pixel weight");
    321           source->pixWeight = NAN;
     315          source->pixWeightNotBad = NAN;
     316          source->pixWeightNotPoor = NAN;
    322317          continue;
    323318        }
Note: See TracChangeset for help on using the changeset viewer.