IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 3, 2006, 3:01:34 PM (20 years ago)
Author:
drobbin
Message:

Updated files to reflect psArray, psVector, & psPixels changes in psLib that set n=0 upon allocation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/imsubtract/pmImageSubtract.c

    r5170 r6511  
    77 *  @author GLG, MHPCC
    88 *
    9  *  @version $Revision: 1.1 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2005-09-28 20:43:52 $
     9 *  @version $Revision: 1.2 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2006-03-04 01:01:33 $
    1111 *
    1212 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    119119    tmp->u = psVectorAlloc(nBF, PS_TYPE_F32);
    120120    tmp->v = psVectorAlloc(nBF, PS_TYPE_F32);
     121    tmp->u->n = tmp->u->nalloc;
     122    tmp->v->n = tmp->v->nalloc;
    121123    tmp->sigma = NULL;
    122124    tmp->xOrder = psVectorAlloc(nBF, PS_TYPE_F32);
     125    tmp->xOrder->n = tmp->xOrder->nalloc;
    123126    tmp->yOrder = psVectorAlloc(nBF, PS_TYPE_F32);
     127    tmp->yOrder->n = tmp->yOrder->nalloc;
    124128    tmp->subIndex = 0;
    125129    tmp->preCalc = NULL;
     
    216220    tmp->u = psVectorAlloc(nBF, PS_TYPE_F32);
    217221    tmp->v = psVectorAlloc(nBF, PS_TYPE_F32);
     222    tmp->u->n = tmp->u->nalloc;
     223    tmp->v->n = tmp->v->nalloc;
    218224    tmp->sigma = psVectorAlloc(nBF, PS_TYPE_F32);
    219225    tmp->xOrder = psVectorAlloc(nBF, PS_TYPE_F32);
     
    223229    tmp->spatialOrder = spatialOrder;
    224230    tmp->preCalc = psArrayAlloc(nBF);
     231    tmp->u->n = tmp->u->nalloc;
     232    tmp->v->n = tmp->v->nalloc;
     233    tmp->sigma->n = tmp->sigma->nalloc;
     234    tmp->xOrder->n = tmp->xOrder->nalloc;
     235    tmp->yOrder->n = tmp->yOrder->nalloc;
     236    tmp->preCalc->n = tmp->preCalc->nalloc;
    225237
    226238    //
     
    352364    } else {
    353365        stamps = (psArray *) psArrayAlloc(xNum * yNum);
     366        stamps->n = stamps->nalloc;
    354367        for (psS32 s = 0 ; s < (xNum * yNum) ; s++) {
    355368            stamps->data[s] = (psPtr *) p_pmStampAlloc(PM_STAMP_REJECTED);
     
    810823            if (stampVector == NULL) {
    811824                stampVector = psVectorAlloc(numSolveParams, PS_TYPE_F64);
     825                stampVector->n = stampVector->nalloc;
    812826                stamp->vector = stampVector;
    813827            } else {
     
    10281042    } else {
    10291043        solution = psVectorAlloc(size, PS_TYPE_F64);
     1044        solution->n = solution->nalloc;
    10301045    }
    10311046
     
    10391054    psImage *sumMatrix = psImageAlloc(size, size, PS_TYPE_F64);
    10401055    psVector *sumVector = psVectorAlloc(size, PS_TYPE_F64);
     1056    sumVector->n = sumVector->nalloc;
    10411057    PS_VECTOR_SET_F64(sumVector, 0.0);
    10421058    PS_IMAGE_SET_F64(sumMatrix, 0.0);
     
    11311147    } else {
    11321148        deviations = psVectorAlloc(stamps->n, PS_TYPE_F32);
     1149        deviations->n = deviations->nalloc;
    11331150        // XXX: Probably not necessary.
    11341151        PS_VECTOR_SET_F32(deviations, 0.0);
Note: See TracChangeset for help on using the changeset viewer.