IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 15492


Ignore:
Timestamp:
Nov 7, 2007, 3:09:49 PM (19 years ago)
Author:
Paul Price
Message:

Adding memory instrumentation for psImageCopy.

Location:
trunk/psLib/src/imageops
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/imageops/psImageStructManip.c

    r15456 r15492  
    88 *  @author Robert DeSonia, MHPCC
    99 *
    10  *  @version $Revision: 1.19 $ $Name: not supported by cvs2svn $
    11  *  @date $Date: 2007-11-05 23:56:33 $
     10 *  @version $Revision: 1.20 $ $Name: not supported by cvs2svn $
     11 *  @date $Date: 2007-11-08 01:09:48 $
    1212 *
    1313 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    161161    psRegion region = {0, 0, 0, 0};
    162162    region = psRegionForImage (input, region);
    163     psImage *result = imageSubset (__FILE__, __LINE__, __func__, output, input,
    164                                    region.x0, region.y0, region.x1, region.y1);
     163    psImage *result = imageSubset(__FILE__, __LINE__, __func__, output, input,
     164                                  region.x0, region.y0, region.x1, region.y1);
    165165    return result;
    166166}
    167167
    168 psImage* psImageCopy(psImage* output,
    169                      const psImage* input,
    170                      psElemType type)
     168psImage* p_psImageCopy(const char *file, unsigned int lineno, const char *func,
     169                       psImage* output, const psImage* input, psElemType type)
    171170{
    172171    psElemType inDatatype;
     
    203202    elementSize = PSELEMTYPE_SIZEOF(inDatatype);
    204203
    205     output = psImageRecycle(output, numCols, numRows, type);
     204    output = p_psImageRecycle(file, lineno, func, output, numCols, numRows, type);
    206205    P_PSIMAGE_SET_COL0(output, input->col0);
    207206    P_PSIMAGE_SET_ROW0(output, input->row0);
  • trunk/psLib/src/imageops/psImageStructManip.h

    r15456 r15492  
    55*  @author Robert DeSonia, MHPCC
    66*
    7 *  @version $Revision: 1.8 $ $Name: not supported by cvs2svn $
    8 *  @date $Date: 2007-11-05 23:56:33 $
     7*  @version $Revision: 1.9 $ $Name: not supported by cvs2svn $
     8*  @date $Date: 2007-11-08 01:09:49 $
    99*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
    1010*/
     
    6464 *
    6565 */
     66#ifdef DOXYGEN
    6667psImage* psImageCopy(
    6768    psImage* output,                   ///< if not NULL, a psImage that could be recycled.
     
    6970    psElemType type                    ///< the desired datatype of the returned copy
    7071);
     72#else // ifdef DOXYGEN
     73psImage* p_psImageCopy(
     74    const char *file,                   ///< File of caller
     75    unsigned int lineno,                ///< Line number of caller
     76    const char *func,                   ///< Function name of caller
     77    psImage* output,                   ///< if not NULL, a psImage that could be recycled.
     78    const psImage* input,              ///< the psImage to copy
     79    psElemType type                    ///< the desired datatype of the returned copy
     80) PS_ATTR_MALLOC;
     81#define psImageCopy(output, input, type) \
     82      p_psImageSubset(__FILE__, __LINE__, __func__, output, input, type)
     83#endif // ifdef DOXYGEN
    7184
    7285/** Trim an image
Note: See TracChangeset for help on using the changeset viewer.