IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 30046


Ignore:
Timestamp:
Dec 15, 2010, 11:37:06 AM (15 years ago)
Author:
bills
Message:

Merge in fix to ppSub assertion failures due to psf fit problems

Location:
tags/ipp-20101206
Files:
13 edited

Legend:

Unmodified
Added
Removed
  • tags/ipp-20101206/psLib

  • tags/ipp-20101206/psLib/src/imageops

  • tags/ipp-20101206/psLib/src/imageops/psImageMapFit.c

    r30033 r30046  
    4848
    4949// map defines the output image dimensions and scaling.
    50 bool psImageMapFit(bool *goodFit, psImageMap *map, const psVector *mask, psVectorMaskType maskValue,
     50bool psImageMapFit(bool *pGoodFit, psImageMap *map, const psVector *mask, psVectorMaskType maskValue,
    5151                   const psVector *x, const psVector *y, const psVector *f, const psVector *df)
    5252{
    5353    // XXX Add Asserts
    5454
    55     *goodFit = false;
     55    *pGoodFit = false;
    5656
    5757    // dimensions of the output map image
     
    8383        map->map->data.F32[0][0]   = psStatsGetValue(map->stats, mean);
    8484        map->error->data.F32[0][0] = psStatsGetValue(map->stats, stdev);
    85         *goodFit = true;
     85        *pGoodFit = true;
    8686        return true;
    8787    }
     
    8989    if (Nx == 1) {
    9090        bool status;
    91         status = psImageMapFit1DinY (goodFit, map, mask, maskValue, x, y, f, df);
     91        status = psImageMapFit1DinY (pGoodFit, map, mask, maskValue, x, y, f, df);
    9292        return status;
    9393    }
    9494    if (Ny == 1) {
    9595        bool status;
    96         status = psImageMapFit1DinX (goodFit, map, mask, maskValue, x, y, f, df);
     96        status = psImageMapFit1DinX (pGoodFit, map, mask, maskValue, x, y, f, df);
    9797        return status;
    9898    }
     
    339339    psFree (Empty);
    340340
    341     *goodFit = true;
     341    *pGoodFit = true;
    342342    return true;
    343343}
    344344
    345345// measure residuals on each pass and clip outliers based on stats
    346 bool psImageMapClipFit(bool *goodFit, psImageMap *map, psStats *stats, psVector *inMask, psVectorMaskType maskValue,
     346bool psImageMapClipFit(bool *pGoodFit, psImageMap *map, psStats *stats, psVector *inMask, psVectorMaskType maskValue,
    347347                       const psVector *x, const psVector *y, const psVector *f, const psVector *df)
    348348{
     
    354354    psAssert(f, "impossible");
    355355
    356     *goodFit = false;
     356    *pGoodFit = false;
    357357
    358358    // the user supplies one of various stats option pairs,
     
    398398        psTrace("psLib.imageops", 6, "Loop iteration %d.  Calling psImageMapFit()\n", N);
    399399        psS32 Nkeep = 0;
    400         if (!psImageMapFit(goodFit, map, mask, maskValue, x, y, f, df)) {
     400        if (!psImageMapFit(pGoodFit, map, mask, maskValue, x, y, f, df)) {
    401401            psError(PS_ERR_UNKNOWN, false, "Could not fit image map.\n");
    402402            psFree(resid);
     
    404404            return false;
    405405        }
    406         if (!goodFit) {
     406        if (!*pGoodFit) {
    407407            psWarning ("bad fit to image map, try something else");
    408408            return true;
     
    463463    psFree(resid);
    464464    if (!inMask) psFree (mask);
    465     *goodFit = true; // XXX probably don't need to set this (set by psImageMapFit)
     465    *pGoodFit = true; // XXX probably don't need to set this (set by psImageMapFit)
    466466    return true;
    467467}
    468468
    469469// map defines the output image dimensions and scaling.
    470 bool psImageMapFit1DinY(bool *goodFit, psImageMap *map, const psVector *mask, psVectorMaskType maskValue,
     470bool psImageMapFit1DinY(bool *pGoodFit, psImageMap *map, const psVector *mask, psVectorMaskType maskValue,
    471471                        const psVector *x, const psVector *y, const psVector *f, const psVector *df)
    472472{
     
    474474    assert (map->binning->nXruff == 1);
    475475
    476     *goodFit = false;
     476    *pGoodFit = false;
    477477
    478478    // dimensions of the output map image
     
    613613    psFree (Empty);
    614614
    615     *goodFit = true;
     615    *pGoodFit = true;
    616616    return true;
    617617}
    618618
    619619// map defines the output image dimensions and scaling.
    620 bool psImageMapFit1DinX(bool *goodFit, psImageMap *map, const psVector *mask, psVectorMaskType maskValue,
     620bool psImageMapFit1DinX(bool *pGoodFit, psImageMap *map, const psVector *mask, psVectorMaskType maskValue,
    621621                        const psVector *x, const psVector *y, const psVector *f, const psVector *df)
    622622{
     
    624624    assert (map->binning->nYruff == 1);
    625625
    626     *goodFit = false;
     626    *pGoodFit = false;
    627627
    628628    // dimensions of the output map image
     
    763763    psFree (Empty);
    764764
    765     *goodFit = true;
     765    *pGoodFit = true;
    766766    return true;
    767767}
  • tags/ipp-20101206/psLib/src/imageops/psImageMapFit.h

    r30033 r30046  
    88
    99// fit the image map to a set of points
    10 bool psImageMapFit(bool *goodFit,
     10bool psImageMapFit(bool *pGoodFit,
    1111                   psImageMap *map,
    1212                   const psVector *mask,
     
    1919
    2020// fit the image map to a set of points
    21 bool psImageMapClipFit(bool *goodFit,
     21bool psImageMapClipFit(bool *pGoodFit,
    2222                       psImageMap *map,
    2323                       psStats *stats,
     
    3030    );
    3131
    32 bool psImageMapFit1DinY(bool *goodFit,
     32bool psImageMapFit1DinY(bool *pGoodFit,
    3333                        psImageMap *map,
    3434                        const psVector *mask,
     
    4040    );
    4141
    42 bool psImageMapFit1DinX(bool *goodFit,
     42bool psImageMapFit1DinX(bool *pGoodFit,
    4343                        psImageMap *map,
    4444                        const psVector *mask,
  • tags/ipp-20101206/psLib/src/types/psMetadata.c

    r29833 r30046  
    13711371            break;
    13721372        case PS_DATA_S64:
    1373             fprintf(fd, "%jd\n", item->data.S64);
     1373            fprintf(fd, "%" PRId64 "\n", item->data.S64);
    13741374            break;
    13751375        case PS_DATA_U8:
     
    13831383            break;
    13841384        case PS_DATA_U64:
    1385             fprintf(fd, "%ju\n", item->data.U64);
     1385            fprintf(fd, "%" PRIu64 "\n", item->data.U64);
    13861386            break;
    13871387        case PS_DATA_F32:
     
    14581458              fprintf(fd, "U64  ");
    14591459              for (int i = 0; i < vector->n; i++) {
    1460                   fprintf(fd, "%ju ", vector->data.U64[i]);
     1460                  fprintf(fd, "%" PRIu64, vector->data.U64[i]);
    14611461              }
    14621462              fprintf(fd, "\n");
     
    14861486              fprintf(fd, "S64  ");
    14871487              for (int i = 0; i < vector->n; i++) {
    1488                   fprintf(fd, "%jd ", vector->data.S64[i]);
     1488                  fprintf(fd, "%" PRId64, vector->data.S64[i]);
    14891489              }
    14901490              fprintf(fd, "\n");
  • tags/ipp-20101206/psModules

  • tags/ipp-20101206/psModules/src/camera/pmFPAfile.c

    r29833 r30046  
    3636        return;
    3737    }
    38     psTrace ("pmFPAfileFree", 5, "freeing %s %ld\n", file->name,(psU64) file->fits);
     38    psTrace ("pmFPAfileFree", 5, "freeing %s %p\n", file->name, file->fits);
    3939    psAssert(!fpaFileFreeStrict || file->fits == NULL, "File %s wasn't closed.", file->name);
    4040
  • tags/ipp-20101206/psModules/src/concepts/pmConceptsAverage.c

    • Property svn:mergeinfo changed (with no actual effect on merging)
  • tags/ipp-20101206/psModules/src/objects

  • tags/ipp-20101206/psModules/src/objects/pmPSF_IO.c

    r29004 r30046  
    6262#include "pmSourceIO.h"
    6363
     64bool pmPSFmodelReadPSFClump (psMetadata *analysis, psMetadata *header);
     65
    6466bool pmPSFmodelCheckDataStatusForView (const pmFPAview *view, const pmFPAfile *file)
    6567{
     
    851853
    852854    // read the psf clump data for each region
     855    status = false;
    853856    if (roAnalysis) {
    854         int nRegions = psMetadataLookupS32 (&status, header, "PSF_CLN");
    855         if (!status) {
    856             // read old-style psf clump data
    857 
    858             char regionName[64];
    859             snprintf (regionName, 64, "PSF.CLUMP.REGION.000");
    860             psMetadataAddS32 (roAnalysis, PS_LIST_TAIL, "PSF.CLUMP.NREGIONS",  PS_META_REPLACE, "psf clump regions", 1);
    861 
    862             psMetadata *regionMD = psMetadataLookupPtr (&status, roAnalysis, regionName);
    863             if (!regionMD) {
    864                 regionMD = psMetadataAlloc();
    865                 psMetadataAddMetadata (roAnalysis, PS_LIST_TAIL, regionName, PS_META_REPLACE, "psf clump region", regionMD);
    866                 psFree (regionMD);
    867             }
    868 
    869             // psf clump data
    870             pmPSFClump psfClump;
    871 
    872             psfClump.X  = psMetadataLookupF32 (&status, header, "PSF_CLX" );  assert(status);
    873             psfClump.Y  = psMetadataLookupF32 (&status, header, "PSF_CLY" );  assert(status);
    874             psfClump.dX = psMetadataLookupF32 (&status, header, "PSF_CLDX");  assert(status);
    875             psfClump.dY = psMetadataLookupF32 (&status, header, "PSF_CLDY");  assert(status);
    876 
    877             psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.X",  PS_META_REPLACE, "psf clump center", psfClump.X);
    878             psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.Y",  PS_META_REPLACE, "psf clump center", psfClump.Y);
    879             psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.DX", PS_META_REPLACE, "psf clump center", psfClump.dX);
    880             psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.DY", PS_META_REPLACE, "psf clump center", psfClump.dY);
    881         } else {
    882             psMetadataAddS32 (roAnalysis, PS_LIST_TAIL, "PSF.CLUMP.NREGIONS",  PS_META_REPLACE, "psf clump regions", nRegions);
    883 
    884             for (int i = 0; i < nRegions; i++) {
    885                 char key[10];
    886                 char regionName[64];
    887                 snprintf (regionName, 64, "PSF.CLUMP.REGION.%03d", i);
    888 
    889                 psMetadata *regionMD = psMetadataLookupPtr (&status, roAnalysis, regionName);
    890                 if (!regionMD) {
    891                     regionMD = psMetadataAlloc();
    892                     psMetadataAddMetadata (roAnalysis, PS_LIST_TAIL, regionName, PS_META_REPLACE, "psf clump region", regionMD);
    893                     psFree (regionMD);
    894                 }
    895 
    896                 // psf clump data
    897                 pmPSFClump psfClump;
    898 
    899                 snprintf (key, 9, "CLX_%03d", i);
    900                 psfClump.X  = psMetadataLookupF32 (&status, header, key);  assert(status);
    901                 snprintf (key, 9, "CLY_%03d", i);
    902                 psfClump.Y  = psMetadataLookupF32 (&status, header, key);  assert(status);
    903                 snprintf (key, 9, "CLDX_%03d", i);
    904                 psfClump.dX = psMetadataLookupF32 (&status, header, key);  assert(status);
    905                 snprintf (key, 9, "CLDY_%03d", i);
    906                 psfClump.dY = psMetadataLookupF32 (&status, header, key);  assert(status);
    907 
    908                 psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.X",  PS_META_REPLACE, "psf clump center", psfClump.X);
    909                 psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.Y",  PS_META_REPLACE, "psf clump center", psfClump.Y);
    910                 psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.DX", PS_META_REPLACE, "psf clump center", psfClump.dX);
    911                 psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.DY", PS_META_REPLACE, "psf clump center", psfClump.dY);
    912             }
    913         }
     857        status = pmPSFmodelReadPSFClump (roAnalysis, header);
     858        if (!status) {
     859            psMetadataAddS32 (roAnalysis, PS_LIST_TAIL, "PSF.CLUMP.NREGIONS",  PS_META_REPLACE, "psf clump regions", 0);
     860        }
     861    }
     862    if (!roAnalysis || !status) {
     863        psWarning ("no PSF.CLUMP data available for PSF model");
    914864    }
    915865
     
    11231073}
    11241074
    1125 // XXX pmPSF to/from Metadata functions were defined for 1.22 and earlier, but were dropped
     1075bool pmPSFmodelReadPSFClump (psMetadata *analysis, psMetadata *header) {
     1076
     1077    bool status = false;;
     1078
     1079    int nRegions = psMetadataLookupS32 (&status, header, "PSF_CLN");
     1080    if (!status) {
     1081        // read old-style psf clump data
     1082
     1083        char regionName[64];
     1084        snprintf (regionName, 64, "PSF.CLUMP.REGION.000");
     1085        psMetadata *regionMD = psMetadataLookupPtr (&status, analysis, regionName);
     1086
     1087        if (!regionMD) {
     1088            regionMD = psMetadataAlloc();
     1089            psMetadataAddMetadata (analysis, PS_LIST_TAIL, regionName, PS_META_REPLACE, "psf clump region", regionMD);
     1090            psFree (regionMD);
     1091        }
     1092
     1093        // psf clump data
     1094        pmPSFClump psfClump;
     1095        psfClump.X  = psMetadataLookupF32 (&status, header, "PSF_CLX" );  if (!status) return false;
     1096        psfClump.Y  = psMetadataLookupF32 (&status, header, "PSF_CLY" );  if (!status) return false;
     1097        psfClump.dX = psMetadataLookupF32 (&status, header, "PSF_CLDX");  if (!status) return false;
     1098        psfClump.dY = psMetadataLookupF32 (&status, header, "PSF_CLDY");  if (!status) return false;
     1099
     1100        psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.X",  PS_META_REPLACE, "psf clump center", psfClump.X);
     1101        psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.Y",  PS_META_REPLACE, "psf clump center", psfClump.Y);
     1102        psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.DX", PS_META_REPLACE, "psf clump center", psfClump.dX);
     1103        psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.DY", PS_META_REPLACE, "psf clump center", psfClump.dY);
     1104        psMetadataAddS32 (analysis, PS_LIST_TAIL, "PSF.CLUMP.NREGIONS",  PS_META_REPLACE, "psf clump regions", 1);
     1105    } else {
     1106        for (int i = 0; i < nRegions; i++) {
     1107            char key[10];
     1108            char regionName[64];
     1109            snprintf (regionName, 64, "PSF.CLUMP.REGION.%03d", i);
     1110
     1111            psMetadata *regionMD = psMetadataLookupPtr (&status, analysis, regionName);
     1112            if (!regionMD) {
     1113                regionMD = psMetadataAlloc();
     1114                psMetadataAddMetadata (analysis, PS_LIST_TAIL, regionName, PS_META_REPLACE, "psf clump region", regionMD);
     1115                psFree (regionMD);
     1116            }
     1117
     1118            // psf clump data
     1119            pmPSFClump psfClump;
     1120
     1121            snprintf (key, 9, "CLX_%03d", i);
     1122            psfClump.X  = psMetadataLookupF32 (&status, header, key);  if (!status) return false;
     1123            snprintf (key, 9, "CLY_%03d", i);
     1124            psfClump.Y  = psMetadataLookupF32 (&status, header, key);  if (!status) return false;
     1125            snprintf (key, 9, "CLDX_%03d", i);
     1126            psfClump.dX = psMetadataLookupF32 (&status, header, key);  if (!status) return false;
     1127            snprintf (key, 9, "CLDY_%03d", i);
     1128            psfClump.dY = psMetadataLookupF32 (&status, header, key);  if (!status) return false;
     1129
     1130            psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.X",  PS_META_REPLACE, "psf clump center", psfClump.X);
     1131            psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.Y",  PS_META_REPLACE, "psf clump center", psfClump.Y);
     1132            psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.DX", PS_META_REPLACE, "psf clump center", psfClump.dX);
     1133            psMetadataAddF32 (regionMD, PS_LIST_TAIL, "PSF.CLUMP.DY", PS_META_REPLACE, "psf clump center", psfClump.dY);
     1134        }
     1135        psMetadataAddS32 (analysis, PS_LIST_TAIL, "PSF.CLUMP.NREGIONS",  PS_META_REPLACE, "psf clump regions", nRegions);
     1136    }
     1137    return true;
     1138}
  • tags/ipp-20101206/psModules/src/objects/pmPSFtry.h

    r30033 r30046  
    100100bool pmPSFtryFitEXT (pmPSFtry *psfTry, pmPSFOptions *options, psImageMaskType maskVal, psImageMaskType markVal);
    101101
    102 bool pmPSFtryMakePSF (bool *goodFit, pmPSFtry *psfTry);
     102bool pmPSFtryMakePSF (bool *pGoodFit, pmPSFtry *psfTry);
    103103
    104104bool pmPSFtryFitPSF (pmPSFtry *psfTry, pmPSFOptions *options, psImageMaskType maskVal, psImageMaskType markVal);
     
    123123);
    124124
    125 bool pmPSFFitShapeParams (bool *goodFit, pmPSF *psf, psArray *sources, psVector *x, psVector *y, psVector *srcMask);
     125bool pmPSFFitShapeParams (bool *pGoodFit, pmPSF *psf, psArray *sources, psVector *x, psVector *y, psVector *srcMask);
    126126
    127127float psVectorSystematicError (psVector *residuals, psVector *errors, float clipFraction);
  • tags/ipp-20101206/psModules/src/objects/pmPSFtryMakePSF.c

    r30033 r30046  
    5050Note: some of the array entries may be NULL (failed fits); ignore them.
    5151 *****************************************************************************/
    52 bool pmPSFtryMakePSF (bool *goodFit, pmPSFtry *psfTry)
     52bool pmPSFtryMakePSF (bool *pGoodFit, pmPSFtry *psfTry)
    5353{
    5454    PS_ASSERT_PTR_NON_NULL(psfTry, false);
     
    7474
    7575    // fit the shape parameters (SXX, SYY, SXY) as a function of position
    76     if (!pmPSFFitShapeParams (goodFit, psf, psfTry->sources, x, y, srcMask)) {
     76    if (!pmPSFFitShapeParams (pGoodFit, psf, psfTry->sources, x, y, srcMask)) {
    7777        psFree(x);
    7878        psFree(y);
    7979        return false;
    8080    }
    81     if (!goodFit) {
     81    if (!*pGoodFit) {
    8282        psWarning ("poor fit to PSF shape parameters for trend order %d, %d, skipping\n", psf->trendNx, psf->trendNy);
    8383        psFree(x);
     
    121121        // the mask is carried from previous steps and updated with this operation
    122122        // the weight is either the flux error or NULL, depending on 'psf->poissonErrorParams'
    123         if (!pmTrend2DFit (goodFit, trend, srcMask, 0xff, x, y, z, NULL)) {
     123        if (!pmTrend2DFit (pGoodFit, trend, srcMask, 0xff, x, y, z, NULL)) {
    124124            psError(PS_ERR_UNKNOWN, false, "failed to build psf model for parameter %d", i);
    125125            psFree(x);
     
    128128            return false;
    129129        }
    130         if (!goodFit) {
     130        if (!*pGoodFit) {
    131131            // if we do not get a good fit (but do not actually hit an error),
    132132            // tell the calling program to try something else
     
    154154
    155155            pmModel *modelPSF = pmModelFromPSF (source->modelEXT, psf);
     156            if (!modelPSF) {
     157                fprintf(f, "modelPSF is NULL\n");
     158                break;
     159            }
     160            if (!source->modelEXT) {
     161                fprintf(f, "source->modelEXT is NULL\n");
     162                break;
     163            }
    156164
    157165            fprintf (f, "%f %f : ", source->modelEXT->params->data.F32[PM_PAR_XPOS], source->modelEXT->params->data.F32[PM_PAR_YPOS]);
     
    178186
    179187// fit the shape parameters using the supplied order (pmPSF->trendNx,trendNy)
    180 bool pmPSFFitShapeParams (bool *goodFit, pmPSF *psf, psArray *sources, psVector *x, psVector *y, psVector *srcMask) {
     188bool pmPSFFitShapeParams (bool *pGoodFit, pmPSF *psf, psArray *sources, psVector *x, psVector *y, psVector *srcMask) {
    181189
    182190    // we are doing a robust fit.  after each pass, we drop points which are more deviant than
     
    234242        trend = psf->params->data[PM_PAR_E0];
    235243        trend->stats->clipIter = 1; // in allocation, this value is set to the value of nIter, but we should use 1 here
    236         status &= pmTrend2DFit (goodFit, trend, srcMask, 0xff, x, y, e0, NULL);
    237         if (!goodFit) {
     244        status &= pmTrend2DFit (pGoodFit, trend, srcMask, 0xff, x, y, e0, NULL);
     245        if (!*pGoodFit) {
    238246            psFree (e0);
    239247            psFree (e1);
     
    249257        trend = psf->params->data[PM_PAR_E1];
    250258        trend->stats->clipIter = 1; // in allocation, this value is set to the value of nIter, but we should use 1 here
    251         status &= pmTrend2DFit (goodFit, trend, srcMask, 0xff, x, y, e1, NULL);
    252         if (!goodFit) {
     259        status &= pmTrend2DFit (pGoodFit, trend, srcMask, 0xff, x, y, e1, NULL);
     260        if (!*pGoodFit) {
    253261            psFree (e0);
    254262            psFree (e1);
     
    264272        trend = psf->params->data[PM_PAR_E2];
    265273        trend->stats->clipIter = 1; // in allocation, this value is set to the value of nIter, but we should use 1 here
    266         status &= pmTrend2DFit (goodFit, trend, srcMask, 0xff, x, y, e2, NULL);
    267         if (!goodFit) {
     274        status &= pmTrend2DFit (pGoodFit, trend, srcMask, 0xff, x, y, e2, NULL);
     275        if (!*pGoodFit) {
    268276            psFree (e0);
    269277            psFree (e1);
  • tags/ipp-20101206/psModules/src/objects/pmTrend2D.c

    r30033 r30046  
    179179}
    180180
    181 bool pmTrend2DFit(bool *goodFit, pmTrend2D *trend, psVector *mask, psVectorMaskType maskVal, const psVector *x,
     181bool pmTrend2DFit(bool *pGoodFit, pmTrend2D *trend, psVector *mask, psVectorMaskType maskVal, const psVector *x,
    182182                  const psVector *y, const psVector *f, const psVector *df)
    183183{
     
    189189
    190190    bool status = false;
    191     *goodFit = false;
     191    *pGoodFit = false;
    192192    // for the psImageMap fit, it is possible to have valid data but no valid solution for
    193193    // example, an isolated cell may not be reached from other cells, making the solution
    194194    // degenerate.  psImageMapFit should probably handle this case, but until it does, we allow
    195     // it to fail on the result, but not yield an error (goodFit = false).
    196     // psVectorClipFitPolynomial2D can not fail in this way (really?), so goodFit is always
     195    // it to fail on the result, but not yield an error (pGoodFit = false).
     196    // psVectorClipFitPolynomial2D can not fail in this way (really?), so pGoodFit is always
    197197    // true
    198198
     
    204204        // of points in the image, and potentially based on the fractional range of the
    205205        // data?
    206         *goodFit = true;
     206        *pGoodFit = true;
    207207        break;
    208208
     
    210210        // XXX supply fraction from trend elements
    211211        // XXX need to add the API which adjusts the scale
    212         status = psImageMapClipFit(goodFit, trend->map, trend->stats, mask, maskVal, x, y, f, df);
     212        status = psImageMapClipFit(pGoodFit, trend->map, trend->stats, mask, maskVal, x, y, f, df);
    213213        break;
    214214
Note: See TracChangeset for help on using the changeset viewer.