IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 4589


Ignore:
Timestamp:
Jul 20, 2005, 3:40:10 PM (21 years ago)
Author:
drobbin
Message:

made minor changes in accordance with newest api-delta doc

Location:
trunk/psLib
Files:
17 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/db/psDB.c

    r4556 r4589  
    1212 *  @author Joshua Hoblitt
    1313 *
    14  *  @version $Revision: 1.39 $ $Name: not supported by cvs2svn $
    15  *  @date $Date: 2005-07-15 02:33:52 $
     14 *  @version $Revision: 1.40 $ $Name: not supported by cvs2svn $
     15 *  @date $Date: 2005-07-21 01:40:10 $
    1616 *
    1717 *  Copyright 2005 Joshua Hoblitt, University of Hawaii
     
    4949// SQL generation functions
    5050static char    *psDBGenerateCreateTableSQL(const char *tableName, const psMetadata *where);
    51 static char    *psDBGenerateSelectRowSQL(const char *tableName, const char *col, const psMetadata *where, psU64 limit);
     51static char    *psDBGenerateSelectRowSQL(const char *tableName, const char *col,
     52        const psMetadata *where, psU64 limit);
    5253static char    *psDBGenerateInsertRowSQL(const char *tableName, const psMetadata *row);
    53 static char    *psDBGenerateUpdateRowSQL(const char *tableName, const psMetadata *where, const psMetadata *values);
    54 static char    *psDBGenerateDeleteRowSQL(const char *tableName, const psMetadata *where, unsigned long long limit);
     54static char    *psDBGenerateUpdateRowSQL(const char *tableName, const psMetadata *where,
     55        const psMetadata *values);
     56static char    *psDBGenerateDeleteRowSQL(const char *tableName, const psMetadata *where,
     57        unsigned long long limit);
    5558static char    *psDBGenerateWhereSQL(const psMetadata *where);
    5659static char    *psDBGenerateSetSQL(const psMetadata *set
     
    8992/*****************************************************************************/
    9093
    91 psDB *psDBInit(const char *host, const char *user, const char *passwd, const char *dbname)
     94psDB *psDBInit(const char *host,
     95               const char *user,
     96               const char *passwd,
     97               const char *dbname)
    9298{
    9399    MYSQL           *mysql;
     
    139145}
    140146
    141 bool psDBCreate(psDB *dbh, const char *dbname)
     147bool psDBCreate(psDB *dbh,
     148                const char *dbname)
    142149{
    143150    char            *query = NULL;
     
    157164}
    158165
    159 bool psDBChange(psDB *dbh, const char *dbname)
     166bool psDBChange(psDB *dbh,
     167                const char *dbname)
    160168{
    161169    // Verify database object is valid
     
    177185}
    178186
    179 bool psDBDrop(psDB *dbh, const char *dbname)
     187bool psDBDrop(psDB *dbh,
     188              const char *dbname)
    180189{
    181190    char            *query = NULL;
     
    195204}
    196205
    197 bool psDBCreateTable(psDB *dbh, const char *tableName, const psMetadata *md)
     206bool psDBCreateTable(psDB *dbh,
     207                     const char *tableName,
     208                     const psMetadata *md)
    198209{
    199210    char            *query;
     
    225236}
    226237
    227 bool psDBDropTable(psDB *dbh, const char *tableName)
     238bool psDBDropTable(psDB *dbh,
     239                   const char *tableName)
    228240{
    229241    char            *query = NULL;
     
    244256}
    245257
    246 psArray *psDBSelectColumn(psDB *dbh, const char *tableName, const char *col, unsigned long long limit)
     258psArray *psDBSelectColumn(psDB *dbh,
     259                          const char *tableName,
     260                          const char *col,
     261                          unsigned long long limit)
    247262{
    248263    MYSQL_RES       *result;            // complete db result set
     
    339354}
    340355
    341 psVector *psDBSelectColumnNum(psDB *dbh, const char *tableName, const char *col, psElemType type, unsigned long long limit)
     356psVector *psDBSelectColumnNum(psDB *dbh,
     357                              const char *tableName,
     358                              const char *col,
     359                              psElemType type,
     360                              unsigned long long limit)
    342361{
    343362    psArray         *stringColumn;      // source psArray
     
    403422}
    404423
    405 psArray *psDBSelectRows(psDB *dbh, const char *tableName, const psMetadata *where, unsigned long long limit)
     424psArray *psDBSelectRows(psDB *dbh,
     425                        const char *tableName,
     426                        const psMetadata *where,
     427                        unsigned long long limit)
    406428{
    407429    MYSQL_RES       *result;            // complete db result set
     
    507529}
    508530
    509 bool psDBInsertOneRow(psDB *dbh, const char *tableName, const psMetadata *row)
     531bool psDBInsertOneRow(psDB *dbh,
     532                      const char *tableName,
     533                      const psMetadata *row)
    510534{
    511535    psArray         *rowSet;           // psArray of row to insert
     
    534558}
    535559
    536 bool psDBInsertRows(psDB *dbh, const char *tableName, const psArray *rowSet)
     560bool psDBInsertRows(psDB *dbh,
     561                    const char *tableName,
     562                    const psArray *rowSet)
    537563{
    538564    psMetadata      *row;               // row of data
     
    635661}
    636662
    637 psArray *psDBDumpRows(psDB *dbh, const char *tableName)
     663psArray *psDBDumpRows(psDB *dbh,
     664                      const char *tableName)
    638665{
    639666    return psDBSelectRows(dbh, tableName, NULL, 0);
    640667}
    641668
    642 psMetadata *psDBDumpCols(psDB *dbh, const char *tableName)
     669psMetadata *psDBDumpCols(psDB *dbh,
     670                         const char *tableName)
    643671{
    644672    MYSQL_RES       *result;
     
    698726}
    699727
    700 psS64 psDBUpdateRows(psDB *dbh, const char *tableName, const psMetadata *where, const psMetadata *values)
     728long psDBUpdateRows(psDB *dbh,
     729                    const char *tableName,
     730                    const psMetadata *where,
     731                    const psMetadata *values)
    701732{
    702733    char            *query;
     
    779810}
    780811
    781 psS64 psDBDeleteRows(psDB *dbh, const char *tableName, const psMetadata *where, unsigned long long limit)
     812long psDBDeleteRows(psDB *dbh,
     813                    const char *tableName,
     814                    const psMetadata *where,
     815                    unsigned long long limit)
    782816{
    783817    char            *query;
     
    818852/*****************************************************************************/
    819853
    820 bool p_psDBRunQuery(psDB *dbh, const char *format)
     854bool p_psDBRunQuery(psDB *dbh,
     855                    const char *format)
    821856{
    822857    // Verify database object is not NULL
     
    835870}
    836871
    837 static inline bool psDBPackRow(MYSQL_BIND *bind, const psMetadata *values, psU32 paramCount)
     872static inline bool psDBPackRow(MYSQL_BIND *bind,
     873                               const psMetadata *values,
     874                               psU32 paramCount)
    838875{
    839876    psListIterator  *cursor;            // row iterator
     
    928965/*****************************************************************************/
    929966
    930 static char *psDBGenerateCreateTableSQL(const char *tableName, const psMetadata *table)
     967static char *psDBGenerateCreateTableSQL(const char *tableName,
     968                                        const psMetadata *table)
    931969{
    932970    char            *query = NULL;      // complete query
     
    10041042}
    10051043
    1006 static char *psDBGenerateSelectRowSQL(const char *tableName, const char *col, const psMetadata *where, psU64 limit)
     1044static char *psDBGenerateSelectRowSQL(const char *tableName,
     1045                                      const char *col,
     1046                                      const psMetadata *where,
     1047                                      psU64 limit)
    10071048{
    10081049    char            *query = NULL;
     
    10411082}
    10421083
    1043 static char *psDBGenerateInsertRowSQL(const char *tableName, const psMetadata *row)
     1084static char *psDBGenerateInsertRowSQL(const char *tableName,
     1085                                      const psMetadata *row)
    10441086{
    10451087    char            *query = NULL;
     
    10971139}
    10981140
    1099 static char *psDBGenerateUpdateRowSQL(const char *tableName, const psMetadata *where, const psMetadata *values)
     1141static char *psDBGenerateUpdateRowSQL(const char *tableName,
     1142                                      const psMetadata *where,
     1143                                      const psMetadata *values)
    11001144{
    11011145    char            *query = NULL;
     
    11311175}
    11321176
    1133 static char *psDBGenerateDeleteRowSQL(const char *tableName, const psMetadata *where, unsigned long long limit)
     1177static char *psDBGenerateDeleteRowSQL(const char *tableName,
     1178                                      const psMetadata *where,
     1179                                      unsigned long long limit)
    11341180{
    11351181    char            *query = NULL;
     
    12611307/*****************************************************************************/
    12621308
    1263 static psElemType psDBMySQLToPType(enum enum_field_types type, unsigned int flags)
     1309static psElemType psDBMySQLToPType(enum enum_field_types type,
     1310                                   unsigned int flags)
    12641311{
    12651312    psHash          *mysqlToSQLTable;   // type lookup table
     
    15501597}
    15511598
    1552 static psPtr psDBMySQLTypeAlloc(enum enum_field_types type, bool isUnsigned)
     1599static psPtr psDBMySQLTypeAlloc(enum enum_field_types type,
     1600                                bool isUnsigned)
    15531601{
    15541602    mysqlType       *mType;
     
    15611609}
    15621610
    1563 static void psDBAddToLookupTable(psHash *lookupTable, psU32 type, const char *string)
     1611static void psDBAddToLookupTable(psHash *lookupTable,
     1612                                 psU32 type,
     1613                                 const char *string)
    15641614{
    15651615    char            *key;
     
    15751625}
    15761626
    1577 static void psDBAddVoidToLookupTable(psHash *lookupTable, psU32 type, psPtr value)
     1627static void psDBAddVoidToLookupTable(psHash *lookupTable,
     1628                                     psU32 type,
     1629                                     psPtr value)
    15781630{
    15791631    char            *key;
     
    16501702#define PS_IS_NAN(type, data, nan) *(type *)data == nan
    16511703
    1652 static bool psDBIsPTypeNaN(psElemType pType, psPtr data)
     1704static bool psDBIsPTypeNaN(psElemType pType,
     1705                           psPtr data)
    16531706{
    16541707    bool    isNaN;
  • trunk/psLib/src/db/psDB.h

    r4540 r4589  
    1010 *  @author Joshua Hoblitt
    1111 *
    12  *  @version $Revision: 1.11 $ $Name: not supported by cvs2svn $
    13  *  @date $Date: 2005-07-12 19:12:00 $
     12 *  @version $Revision: 1.12 $ $Name: not supported by cvs2svn $
     13 *  @date $Date: 2005-07-21 01:40:10 $
    1414 *
    1515 *  Copyright 2005 Joshua Hoblitt, University of Hawaii
     
    4040/** Opens a new database connection
    4141 *
    42  *  @return A new psDB object if the database connection is successful or NULL on
     42 *  @return psDB*:      A new psDB object if the database connection is successful or NULL on
    4343 *  failure.
    4444 */
     
    5050);
    5151
    52 /** Closes a database connection
    53  */
     52/** Closes a database connection  */
    5453void psDBCleanup(
    5554    psDB *dbh                          ///< Database handle
     
    5857/** Creates a new database namespace
    5958 *
    60  * @return true on success
     59 * @return bool:    true on success
    6160 */
    6261bool psDBCreate(
     
    6766/** Changes the current database namespace
    6867 *
    69  * @return true on success
     68 * @return bool:    true on success
    7069 */
    7170bool psDBChange(
     
    7675/** Drops a database namespace
    7776 *
    78  * @return true on success
     77 * @return bool:    true on success
    7978 */
    8079bool psDBDrop(
     
    8988 * dialect is provided.  Caveat emptor.
    9089 *
    91  * @return true on success
     90 * @return bool:    true on success
    9291 */
    9392bool p_psDBRunQuery(
     
    114113 * Key" or "Key".  Comments are otherwise ignored.
    115114 *
    116  * @return true on success
     115 * @return bool:    true on success
    117116 */
    118117bool psDBCreateTable(
     
    124123/** Deletes a database table
    125124 *
    126  * @return true on success
     125 * @return bool:    true on success
    127126*/
    128127bool psDBDropTable(
     
    137136 * entire range is returned.
    138137 *
    139  * @return A psArray of strings or NULL on failure
     138 * @return psArray*:    A psArray of strings or NULL on failure
    140139 */
    141140psArray *psDBSelectColumn(
     
    152151 * entire range is returned.  The data in the column is cast to to "pType".
    153152 *
    154  * @return A psVector or NULL on failure
     153 * @return psVector*:   A psVector or NULL on failure
    155154 */
    156155psVector *psDBSelectColumnNum(
     
    174173 * string, e.g. "", to match NULL field values.
    175174 *
    176  * @return A psArray of psMetadata or NULL on failure
     175 * @return psArray*:    A psArray of psMetadata or NULL on failure
    177176 */
    178177psArray *psDBSelectRows(
     
    192191 * specified in "row" that do not exist in "tableName", the insert will fail.
    193192 *
    194  * @return true on success
     193 * @return bool:    true on success
    195194 */
    196195bool psDBInsertOneRow(
     
    207206 * those used in psDBInsertOneRow().
    208207 *
    209  * @return true on success
     208 * @return bool:    true on success
    210209 */
    211210bool psDBInsertRows(
     
    220219 * the same psMetadata format as used in psDBInsertOneRow() & psDBInsertRows().
    221220 *
    222  * @return A psArray of psMetadata or NULL on failure
     221 * @return psArray*:    A psArray of psMetadata or NULL on failure
    223222 */
    224223psArray *psDBDumpRows(
     
    233232 * psMetadata structure where psMetadataItem.name contains the column's name.
    234233 *
    235  * @return A psMetadata containing either a psArrays or psVector per column
     234 * @return psMetadata*:     A psMetadata containing either a psArrays or psVector per column
    236235 */
    237236psMetadata *psDBDumpCols(
     
    249248 * used in psDBInsertOneRow(), etc.
    250249 *
    251  * @return The number of rows modified or a negative value on error
    252  */
    253 psS64 psDBUpdateRows(
     250 * @return long:    The number of rows modified or a negative value on error
     251 */
     252long psDBUpdateRows(
    254253    psDB *dbh,                         ///< Database handle
    255254    const char *tableName,             ///< Table name
     
    266265 * the number of rows that were dropped, only 1 will be returned on success.
    267266 *
    268  * @return The number of rows removed or a negative value on error
    269  */
    270 psS64 psDBDeleteRows(
     267 * @return long:    The number of rows removed or a negative value on error
     268 */
     269long psDBDeleteRows(
    271270    psDB *dbh,                         ///< Database handle
    272271    const char *tableName,             ///< Table name
  • trunk/psLib/src/imageops/psImagePixelManip.c

    r4544 r4589  
    1010 *  @author Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.6 $ $Name: not supported by cvs2svn $
    13  *  @date $Date: 2005-07-12 19:33:49 $
     12 *  @version $Revision: 1.7 $ $Name: not supported by cvs2svn $
     13 *  @date $Date: 2005-07-21 01:40:10 $
    1414 *
    1515 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    187187int psImageOverlaySection(psImage* image,
    188188                          const psImage* overlay,
    189                           int col0,
    190                           int row0,
     189                          int x0,
     190                          int y0,
    191191                          const char *op)
    192192{
     
    229229    overlayNumRows = overlay->numRows;
    230230    overlayNumCols = overlay->numCols;
    231     imageRowLimit = row0 + overlayNumRows;
    232     imageColLimit = col0 + overlayNumCols;
     231    imageRowLimit = y0 + overlayNumRows;
     232    imageColLimit = x0 + overlayNumCols;
    233233
    234234    /* check to see if overlay is within the input image */
    235     if ( row0 < 0 ||
    236             col0 < 0 ||
     235    if ( y0 < 0 ||
     236            x0 < 0 ||
    237237            imageRowLimit > imageNumRows ||
    238238            imageColLimit > imageNumCols) {
     
    240240        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    241241                PS_ERRORTEXT_psImage_SUBSET_RANGE_INVALID,
    242                 col0, imageColLimit, row0, imageRowLimit,
     242                x0, imageColLimit, y0, imageRowLimit,
    243243                imageNumCols, imageNumRows);
    244244        return pixelsOverlaid;
     
    247247
    248248    #define psImageOverlayLoop(DATATYPE,OP) { \
    249         for (int row=row0;row<imageRowLimit;row++) { \
     249        for (int row=y0;row<imageRowLimit;row++) { \
    250250            ps##DATATYPE* imageRow = image->data.DATATYPE[row]; \
    251             ps##DATATYPE* overlayRow = overlay->data.DATATYPE[row-row0]; \
    252             for (int col=col0;col<imageColLimit;col++) { \
    253                 imageRow[col] OP overlayRow[col-col0]; \
    254             } \
    255         } \
    256         pixelsOverlaid += (imageRowLimit - row0) * (imageColLimit - col0); \
     251            ps##DATATYPE* overlayRow = overlay->data.DATATYPE[row-y0]; \
     252            for (int col=x0;col<imageColLimit;col++) { \
     253                imageRow[col] OP overlayRow[col-x0]; \
     254            } \
     255        } \
     256        pixelsOverlaid += (imageRowLimit - y0) * (imageColLimit - x0); \
    257257    }
    258258
  • trunk/psLib/src/imageops/psImagePixelManip.h

    r4540 r4589  
    88 *  @author Robert DeSonia, MHPCC
    99 *
    10  *  @version $Revision: 1.7 $ $Name: not supported by cvs2svn $
    11  *  @date $Date: 2005-07-12 19:12:01 $
     10 *  @version $Revision: 1.8 $ $Name: not supported by cvs2svn $
     11 *  @date $Date: 2005-07-21 01:40:10 $
    1212 *
    1313 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    8383    psImage* image,                    ///< target image
    8484    const psImage* overlay,            ///< the overlay image
    85     int col0,                          ///< the column to start overlay
    86     int row0,                          ///< the row to start overlay
     85    int x0,                            ///< the column to start overlay
     86    int y0,                            ///< the row to start overlay
    8787    const char *op                     ///< the operation to perform for overlay
    8888);
  • trunk/psLib/src/math/psMatrix.c

    r4540 r4589  
    2121 *  @author Robert DeSonia, MHPCC
    2222 *
    23  *  @version $Revision: 1.35 $ $Name: not supported by cvs2svn $
    24  *  @date $Date: 2005-07-12 19:12:01 $
     23 *  @version $Revision: 1.36 $ $Name: not supported by cvs2svn $
     24 *  @date $Date: 2005-07-21 01:40:10 $
    2525 *
    2626 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    9595
    9696/** Static function to copy psF32 or psF64 vector data to a GSL vector */
    97 static void  psVectorToGslVector(gsl_vector *outGslVector, const psVector *inVector)
     97static void  psVectorToGslVector(gsl_vector *outGslVector,
     98                                 const psVector *inVector)
    9899{
    99100    psU32 i = 0;
     
    112113
    113114/** Static function to copy GSL vector data to a psF32 or psF64 vector */
    114 static void gslVectorToPsVector(psVector *outVector, gsl_vector *inGslVector)
     115static void gslVectorToPsVector(psVector *outVector,
     116                                gsl_vector *inGslVector)
    115117{
    116118    psU32 i = 0;
     
    129131
    130132/** Static function to copy psF32 or psF64 image data to a GSL matrix */
    131 static void  psImageToGslMatrix(gsl_matrix *outGslMatrix, const psImage *inImage)
     133static void  psImageToGslMatrix(gsl_matrix *outGslMatrix,
     134                                const psImage *inImage)
    132135{
    133136    psU32 i = 0;
     
    155158
    156159/** Static function to copy GSL matrix data to a psF32 or psF64 image */
    157 static void gslMatrixToPsImage(psImage *outImage, gsl_matrix *inGslMatrix)
     160static void gslMatrixToPsImage(psImage *outImage,
     161                               gsl_matrix *inGslMatrix)
    158162{
    159163    psU32 i = 0;
     
    185189/*****************************************************************************/
    186190
    187 psImage* psMatrixLUD(psImage* out, psVector** perm, psImage* in)
     191psImage* psMatrixLUD(psImage* out,
     192                     psVector** perm,
     193                     const psImage* in)
    188194{
    189195    psS32 signum = 0;
     
    243249}
    244250
    245 psVector* psMatrixLUSolve(psVector* out, const psImage* LU, const psVector* RHS,
     251psVector* psMatrixLUSolve(psVector* out,
     252                          const psImage* LU,
     253                          const psVector* RHS,
    246254                          const psVector* perm)
    247255{
     
    298306}
    299307
    300 psImage* psMatrixInvert(psImage* out, const psImage* in, float *determinant)
     308psImage* psMatrixInvert(psImage* out,
     309                        const psImage* in,
     310                        float *determinant)
    301311{
    302312    psS32 signum = 0;
     
    346356}
    347357
    348 float *psMatrixDeterminant(const psImage* in)
     358float psMatrixDeterminant(const psImage* in)
    349359{
    350360    psS32 signum = 0;
    351361    psS32 numRows = 0;
    352362    psS32 numCols = 0;
    353     psF32 *det = NULL;
     363    psF32 det = 0;
    354364    gsl_matrix *lu = NULL;
    355365    gsl_permutation *perm = NULL;
    356366
    357     #define DETERMINANT_EXIT { return NULL; }
     367    #define DETERMINANT_EXIT { return 0; }
    358368    // Error checks
    359369    PS_ASSERT_GENERAL_IMAGE_NON_NULL(in, DETERMINANT_EXIT);
     
    372382
    373383    // Calculate determinant
    374     det = (psF32*)psAlloc(sizeof(psF32));
     384    //    det = psAlloc(sizeof(psF32));
    375385    gsl_linalg_LU_decomp(lu, perm, &signum);
    376     *det = (psF32)gsl_linalg_LU_det(lu, signum);
     386    det = (psF32)gsl_linalg_LU_det(lu, signum);
    377387
    378388    // Free GSL structs
     
    383393}
    384394
    385 psImage* psMatrixMultiply(psImage* out, psImage* in1, psImage* in2)
     395psImage* psMatrixMultiply(psImage* out,
     396                          const psImage* in1,
     397                          const psImage* in2)
    386398{
    387399    gsl_matrix *m1 = NULL;
     
    434446}
    435447
    436 psImage* psMatrixTranspose(psImage* out, const psImage* in)
     448psImage* psMatrixTranspose(psImage* out,
     449                           const psImage* in)
    437450{
    438451    psU32 i = 0;
     
    480493}
    481494
    482 psImage* psMatrixEigenvectors(psImage* out, psImage* in)
     495psImage* psMatrixEigenvectors(psImage* out,
     496                              const psImage* in)
    483497{
    484498    psS32 numRows = 0;
     
    529543}
    530544
    531 psVector* psMatrixToVector(psVector* outVector, const psImage* inImage)
     545psVector* psMatrixToVector(psVector* outVector,
     546                           const psImage* inImage)
    532547{
    533548    psS32 size = 0;
     
    593608}
    594609
    595 psImage* psVectorToMatrix(psImage* outImage, const psVector* inVector)
     610psImage* psVectorToMatrix(psImage* outImage,
     611                          const psVector* inVector)
    596612{
    597613    psS32 size = 0;
  • trunk/psLib/src/math/psMatrix.h

    r4388 r4589  
    2121 *  @author Ross Harman, MHPCC
    2222 *
    23  *  @version $Revision: 1.19 $ $Name: not supported by cvs2svn $
    24  *  @date $Date: 2005-06-25 01:15:01 $
     23 *  @version $Revision: 1.20 $ $Name: not supported by cvs2svn $
     24 *  @date $Date: 2005-07-21 01:40:10 $
    2525 *
    2626 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    4545    psImage* out,                      ///< Image to return, or NULL.
    4646    psVector** perm,                   ///< Output permutation vector used by psMatrixLUSolve.
    47     psImage* in                        ///< Image to decompose.
     47    const psImage* in                  ///< Image to decompose.
    4848);
    4949
     
    8787 *  @return  float: Determinant from psImage.
    8888 */
    89 float *psMatrixDeterminant(
     89float psMatrixDeterminant(
    9090    const psImage* in                  ///< Image used to calculate determinant.
    9191);
     
    102102psImage* psMatrixMultiply(
    103103    psImage* out,                      ///< Matrix to return, or NULL.
    104     psImage* in1,                      ///< First input image.
    105     psImage* in2                       ///< Second input image.
     104    const psImage* in1,                ///< First input image.
     105    const psImage* in2                 ///< Second input image.
    106106);
    107107
     
    116116 */
    117117psImage* psMatrixTranspose(
    118     psImage* out,                 ///< Image to return, or NULL
    119     const psImage* inImage             ///< Image to transpose
     118    psImage* out,                      ///< Image to return, or NULL
     119    const psImage* in                  ///< Image to transpose
    120120);
    121121
     
    130130psImage* psMatrixEigenvectors(
    131131    psImage* out,                      ///< Eigenvectors to return, or NULL.
    132     psImage* in                        ///< Input image.
     132    const psImage* in                  ///< Input image.
    133133);
    134134
  • trunk/psLib/src/sys/psMemory.c

    r4556 r4589  
    88*  @author Robert Lupton, Princeton University
    99*
    10 *  @version $Revision: 1.59 $ $Name: not supported by cvs2svn $
    11 *  @date $Date: 2005-07-15 02:33:54 $
     10*  @version $Revision: 1.60 $ $Name: not supported by cvs2svn $
     11*  @date $Date: 2005-07-21 01:40:10 $
    1212*
    1313*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    102102}
    103103
    104 static void memProblemCallbackDefault( psMemBlock* ptr, const char *file, unsigned int lineno)
     104static void memProblemCallbackDefault(psMemBlock* ptr,
     105                                      const char *file,
     106                                      unsigned int lineno)
    105107{
    106108    if (ptr->refCounter < 1) {
     
    120122 * N.b. If the block wasn't allocated by psAlloc, it will appear corrupted
    121123 */
    122 static psS32 checkMemBlock(const psMemBlock* m, const char *funcName)
     124static psS32 checkMemBlock(const psMemBlock* m,
     125                           const char *funcName)
    123126{
    124127    // n.b. since this is called by psMemCheckCorruption while the memblock list is mutex locked,
     
    286289}
    287290
    288 psPtr p_psAlloc(size_t size, const char *file, unsigned int lineno)
     291psPtr p_psAlloc(size_t size,
     292                const char *file,
     293                unsigned int lineno)
    289294{
    290295
     
    370375}
    371376
    372 psPtr p_psRealloc(psPtr vptr, size_t size, const char *file, unsigned int lineno)
     377psPtr p_psRealloc(psPtr vptr,
     378                  size_t size,
     379                  const char *file,
     380                  unsigned int lineno)
    373381{
    374382    size = (size < recycleBinSize[0]) ? recycleBinSize[0] : size; // set the minimum size to allocate
     
    424432}
    425433
    426 void p_psFree(psPtr vptr, const char *file, unsigned int lineno)
     434void p_psFree(psPtr vptr,
     435              const char *filename,
     436              unsigned int lineno)
    427437{
    428438    if (vptr == NULL) {
     
    434444
    435445        psAbort(__func__,PS_ERRORTEXT_psMemory_MULTIPLE_FREE,
    436                 ptr->id, ptr->file, ptr->lineno, file, lineno);
     446                ptr->id, ptr->file, ptr->lineno, filename, lineno);
    437447    }
    438448
    439449    if (checkMemBlock(ptr, __func__) != 0) {
    440         memProblemCallback(ptr, file, lineno);
     450        memProblemCallback(ptr, filename, lineno);
    441451        psAbort(__func__,"Memory Corruption Detected.");
    442452    }
    443453
    444     (void)p_psMemDecrRefCounter(vptr, file, lineno);    // this handles the free, if required.
     454    (void)p_psMemDecrRefCounter(vptr, filename, lineno);    // this handles the free, if required.
    445455}
    446456
     
    448458 * Check for memory leaks.
    449459 */
    450 psS32 psMemCheckLeaks(psMemId id0, psMemBlock* ** arr, FILE * fd, psBool persistence)
     460int psMemCheckLeaks(psMemId id0,
     461                    psMemBlock* ** arr,
     462                    FILE * fd,
     463                    psBool persistence)
    451464{
    452465    psS32 nleak = 0;
     
    527540
    528541// increment and return refCounter
    529 psPtr p_psMemIncrRefCounter(psPtr vptr, const char *file, psS32 lineno)
     542psPtr p_psMemIncrRefCounter(psPtr vptr,
     543                            const char *file,
     544                            psS32 lineno)
    530545{
    531546    psMemBlock* ptr;
     
    549564
    550565// decrement and return refCounter
    551 psPtr p_psMemDecrRefCounter(psPtr vptr, const char *file, psS32 lineno)
     566psPtr p_psMemDecrRefCounter(psPtr vptr,
     567                            const char *file,
     568                            psS32 lineno)
    552569{
    553570    if (vptr == NULL) {
     
    640657}
    641658
    642 void psMemSetDeallocator(psPtr ptr, psFreeFunc freeFunc)
     659void psMemSetDeallocator(psPtr ptr,
     660                         psFreeFunc freeFunc)
    643661{
    644662    if (ptr == NULL) {
     
    655673
    656674}
    657 psFreeFunc psMemGetDeallocator(psPtr ptr)
     675psFreeFunc psMemGetDeallocator(const psPtr ptr)
    658676{
    659677    if (ptr == NULL) {
     
    685703}
    686704
    687 void p_psMemSetPersistent(psPtr vptr, bool value)
     705void p_psMemSetPersistent(psPtr vptr,
     706                          bool value)
    688707{
    689708    if (vptr == NULL) {
  • trunk/psLib/src/sys/psMemory.h

    r4578 r4589  
    1212 *  @ingroup MemoryManagement
    1313 *
    14  *  @version $Revision: 1.46 $ $Name: not supported by cvs2svn $
    15  *  @date $Date: 2005-07-18 20:54:22 $
     14 *  @version $Revision: 1.47 $ $Name: not supported by cvs2svn $
     15 *  @date $Date: 2005-07-21 01:40:10 $
    1616 *
    1717 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    169169 */
    170170psFreeFunc psMemGetDeallocator(
    171     psPtr ptr                          ///< the memory block
     171    const psPtr ptr                          ///< the memory block
    172172);
    173173
     
    239239void p_psFree(
    240240    psPtr ptr,                         ///< Pointer to free
    241     const char *file,                  ///< File of call
     241    const char *filename,              ///< File of call
    242242    unsigned int lineno                ///< Line number of call
    243243);
     
    260260 *  If memory leaks are found, the Memory Problem callback will be called as well.
    261261 *
    262  *  return psS32  number of memory blocks found as 'leaks', i.e., the number of currently allocated memory
     262 *  @return int  number of memory blocks found as 'leaks', i.e., the number of currently allocated memory
    263263 *              blocks above id0 that have not been freed.
    264264 *  @see psAlloc, psFree, psgetMemId, psMemProblemCallbackSet
    265265 *  @ingroup memTracing
    266266 */
    267 psS32 psMemCheckLeaks(
     267int psMemCheckLeaks(
    268268    psMemId id0,                       ///< don't list blocks with id < id0
    269269    psMemBlock* ** arr,                ///< pointer to array of pointers to leaked blocks, or NULL
     
    275275 *  i.e., invalid markers that signify a buffer under/overflow.
    276276 *
     277 *  @return int
     278 *
    277279 *  @ingroup memTracing
    278280 */
     
    283285/** Return reference counter
    284286 *
     287 *  @return psReferenceCount
     288 *
    285289 *  @ingroup memRefCount
    286290 */
     
    290294
    291295/** Increment reference counter and return the pointer
     296 *
     297 *  @return psPtr
    292298 *
    293299 *  @ingroup memRefCount
  • trunk/psLib/src/types/psLookupTable.c

    r4556 r4589  
    77*  @author Ross Harman, MHPCC
    88*
    9 *  @version $Revision: 1.23 $ $Name: not supported by cvs2svn $
    10 *  @date $Date: 2005-07-15 02:33:54 $
     9*  @version $Revision: 1.24 $ $Name: not supported by cvs2svn $
     10*  @date $Date: 2005-07-21 01:40:10 $
    1111*
    1212*  Copyright 2004-2005 Maui High Performance Computing Center, Univ. of Hawaii
     
    8383/** Removes leading and trailing whitespace and # characters from a string. The cleaned string is a new null
    8484 *  terminated copy of the original input string. */
    85 static char *cleanString(char *inString, int sLen)
     85static char *cleanString(char *inString,
     86                         int sLen)
    8687{
    8788    char *ptrB = NULL;
     
    114115/** Returns cleaned token based on delimiter, but not including delimiter. Also changes the pointer location
    115116 * the beginning of the string. Tokens are newly allocated null terminated strings. */
    116 static char* getToken(char **inString, char *delimiter, psParseErrorType *status)
     117static char* getToken(char **inString,
     118                      char *delimiter,
     119                      psParseErrorType *status)
    117120{
    118121    char *cleanToken = NULL;
     
    141144
    142145/** Returns single parsed value as a psS32. The input string must be cleaned and null terminated. */
    143 static psS32 parseS32(char *inString, psParseErrorType *status)
     146static psS32 parseS32(char *inString,
     147                      psParseErrorType *status)
    144148{
    145149    char *end = NULL;
     
    158162
    159163/** Returns single parsed value as a psS64. The input string must be cleaned and null terminated. */
    160 static psS64 parseS64(char *inString, psParseErrorType *status)
     164static psS64 parseS64(char *inString,
     165                      psParseErrorType *status)
    161166{
    162167    char *end = NULL;
     
    174179
    175180/** Returns single parsed value as a psF32. The input string must be cleaned and null terminated. */
    176 static psF32 parseF32(char *inString, psParseErrorType *status)
     181static psF32 parseF32(char *inString,
     182                      psParseErrorType *status)
    177183{
    178184    char *end = NULL;
     
    190196
    191197/** Returns single parsed value as a psF64. The input string must be cleaned and null terminated. */
    192 static psF64 parseF64(char *inString, psParseErrorType *status)
     198static psF64 parseF64(char *inString,
     199                      psParseErrorType *status)
    193200{
    194201    char *end = NULL;
     
    207214/** Returns single parsed value as a double precision number. The input string must be cleaned and null
    208215 * terminated. */
    209 static void parseValue(psVector *vec, psU64 index, char* strValue, psParseErrorType *status)
     216static void parseValue(psVector *vec,
     217                       psU64 index,
     218                       char* strValue,
     219                       psParseErrorType *status)
    210220{
    211221    psElemType type;
     
    254264/*****************************************************************************/
    255265
    256 psLookupTable* psLookupTableAlloc(const char *fileName, const char *format, long indexCol)
     266psLookupTable* psLookupTableAlloc(const char *filename,
     267                                  const char *format,
     268                                  long indexCol)
    257269{
    258270    psLookupTable *outTable = NULL;
    259271
    260272    // Can't read table if you don't know its name
    261     PS_ASSERT_PTR_NON_NULL(fileName,NULL);
     273    PS_ASSERT_PTR_NON_NULL(filename,NULL);
    262274
    263275    // Can't read table if you don't know its format
     
    271283
    272284    // Allocate and set file name and format strings
    273     outTable->filename = psStringCopy(fileName);
     285    outTable->filename = psStringCopy(filename);
    274286    outTable->format = psStringCopy(format);
    275287
     
    396408}
    397409
    398 psArray *psVectorsReadFromFile(const char *filename, const char *format)
     410psArray *psVectorsReadFromFile(const char *filename,
     411                               const char *format)
    399412{
    400413    psArray*          outputArray = NULL;
     
    548561}
    549562
    550 psLookupTable *psLookupTableImport(psLookupTable *table, const psArray *vectors, long indexCol)
     563psLookupTable *psLookupTableImport(psLookupTable *table,
     564                                   const psArray *vectors,
     565                                   long indexCol)
    551566{
    552567    psLookupTable* outputTable = NULL;
     
    745760}
    746761
    747 double psLookupTableInterpolate(const psLookupTable *table, double index, long column)
     762double psLookupTableInterpolate(const psLookupTable *table,
     763                                double index,
     764                                long column)
    748765{
    749766    psU64 hiIdx = 0;
     
    818835}
    819836
    820 psVector* psLookupTableInterpolateAll(const psLookupTable *table, double index)
     837psVector* psLookupTableInterpolateAll(const psLookupTable *table,
     838                                      double index)
    821839{
    822840    long numCols = 0;
  • trunk/psLib/src/types/psLookupTable.h

    r4556 r4589  
    77*  @author Ross Harman, MHPCC
    88*
    9 *  @version $Revision: 1.10 $ $Name: not supported by cvs2svn $
    10 *  @date $Date: 2005-07-15 02:33:54 $
     9*  @version $Revision: 1.11 $ $Name: not supported by cvs2svn $
     10*  @date $Date: 2005-07-21 01:40:10 $
    1111*
    1212*  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    6868 */
    6969psLookupTable* psLookupTableAlloc(
    70     const char *fileName,           ///< Name of file to read
     70    const char *filename,           ///< Name of file to read
    7171    const char *format,             ///< scanf-like format string
    7272    long indexCol                    ///< Column of the index vector (starting at zero)
  • trunk/psLib/src/types/psMetadata.c

    r4556 r4589  
    1212*  @author Ross Harman, MHPCC
    1313*
    14 *  @version $Revision: 1.71 $ $Name: not supported by cvs2svn $
    15 *  @date $Date: 2005-07-15 02:33:54 $
     14*  @version $Revision: 1.72 $ $Name: not supported by cvs2svn $
     15*  @date $Date: 2005-07-21 01:40:10 $
    1616*
    1717*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    6969/*****************************************************************************/
    7070
    71 static psMetadataItem* makeMetaMulti(psHash* table, const char* key, psMetadataItem* existing)
     71static psMetadataItem* makeMetaMulti(psHash* table,
     72                                     const char* key,
     73                                     psMetadataItem* existing)
    7274{
    7375
     
    99101static void metadataItemFree(psMetadataItem* metadataItem)
    100102{
    101     psMetadataType type;
     103    psDataType type;
    102104
    103105    type = metadataItem->type;
     
    141143/*****************************************************************************/
    142144
    143 psMetadataItem* psMetadataItemAlloc(const char *name, psMetadataType type,
    144                                     const char *comment, ...)
     145psMetadataItem* psMetadataItemAlloc(const char *name,
     146                                    psDataType type,
     147                                    const char *comment,
     148                                    ...)
    145149{
    146150    va_list argPtr;
     
    173177METADATAITEM_ALLOC_TYPE(Bool,psBool,PS_META_BOOL)
    174178
    175 psMetadataItem* psMetadataItemAllocV(const char *name, psMetadataType type,
    176                                      const char *comment, va_list argPtr)
     179psMetadataItem* psMetadataItemAllocV(const char *name,
     180                                     psDataType type,
     181                                     const char *comment,
     182                                     va_list argPtr)
    177183{
    178184    psMetadataItem* metadataItem = NULL;
     
    268274}
    269275
    270 bool psMetadataAddItem(psMetadata *md, const psMetadataItem *item, long location, psS32 flags)
     276bool psMetadataAddItem(psMetadata *md,
     277                       const psMetadataItem *item,
     278                       int location,
     279                       psS32 flags)
    271280{
    272281    char * key = NULL;
     
    360369}
    361370
    362 bool psMetadataAdd(psMetadata *md, long location, const char *name,
    363                    int format, const char *comment, ...)
     371bool psMetadataAdd(psMetadata *md,
     372                   long location,
     373                   const char *name,
     374                   int format,
     375                   const char *comment,
     376                   ...)
    364377{
    365378    va_list argPtr;
     
    372385}
    373386
    374 bool psMetadataAddV(psMetadata *md, long location, const char *name,
    375                     int format, const char *comment, va_list list)
     387bool psMetadataAddV(psMetadata *md,
     388                    long location,
     389                    const char *name,
     390                    int format,
     391                    const char *comment,
     392                    va_list list)
    376393{
    377394    psMetadataItem* metadataItem = NULL;
     
    409426METADATA_ADD_TYPE(Array,psArray*,PS_META_ARRAY)
    410427
    411 psBool psMetadataRemove(psMetadata *md, long where, const char *key)
     428psBool psMetadataRemove(psMetadata *md,
     429                        long where,
     430                        const char *key)
    412431{
    413432    PS_ASSERT_PTR_NON_NULL(md,NULL);
     
    477496}
    478497
    479 psMetadataItem* psMetadataLookup(const psMetadata *md, const char *key)
     498psMetadataItem* psMetadataLookup(const psMetadata *md,
     499                                 const char *key)
    480500{
    481501    psHash* mdTable = NULL;
     
    493513}
    494514
    495 void* psMetadataLookupPtr(bool *status, const psMetadata *md, const char *key)
     515void* psMetadataLookupPtr(bool *status,
     516                          const psMetadata *md,
     517                          const char *key)
    496518{
    497519    psMetadataItem *metadataItem = NULL;
     
    580602psMetadataLookupNumTYPE(Bool)
    581603
    582 psMetadataItem* psMetadataGet(const psMetadata *md, long location)
     604psMetadataItem* psMetadataGet(const psMetadata *md,
     605                              int location)
    583606{
    584607    psMetadataItem* entry = NULL;
  • trunk/psLib/src/types/psMetadata.h

    r4556 r4589  
    1111*  @author Ross Harman, MHPCC
    1212*
    13 *  @version $Revision: 1.53 $ $Name: not supported by cvs2svn $
    14 *  @date $Date: 2005-07-15 02:33:54 $
     13*  @version $Revision: 1.54 $ $Name: not supported by cvs2svn $
     14*  @date $Date: 2005-07-21 01:40:10 $
    1515*
    1616*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    118118    const psS32 id;                    ///< Unique ID for metadata item.
    119119    psString name;                     ///< Name of metadata item.
    120     psMetadataType type;               ///< Type of metadata item.
     120    psDataType type;                   ///< Type of metadata item.
    121121    union {
    122122        psBool B;                      ///< boolean data
     
    149149psMetadataItem* psMetadataItemAlloc(
    150150    const char *name,                  ///< Name of metadata item.
    151     psMetadataType type,               ///< Type of metadata item.
     151    psDataType type,                   ///< Type of metadata item.
    152152    const char *comment,               ///< Comment for metadata item.
    153153    ...                                ///< Arguments for name formatting and metadata item data.
     
    238238psMetadataItem* psMetadataItemAllocV(
    239239    const char *name,                  ///< Name of metadata item.
    240     psMetadataType type,               ///< Type of metadata item.
     240    psDataType type,               ///< Type of metadata item.
    241241    const char *comment,               ///< Comment for metadata item.
    242242    va_list list                       ///< Arguments for name formatting and metadata item data.
     
    263263    psMetadata*  md,                   ///< Metadata collection to insert metadat item.
    264264    const psMetadataItem* item,        ///< Metadata item to be added.
    265     long location,                     ///< Index number, PS_LIST_HEAD, or PS_LIST_TAIL
     265    int location,                      ///< Index number, PS_LIST_HEAD, or PS_LIST_TAIL
    266266    psS32 flags                        ///< Options flag mask, see psMetadataFlags enum
    267267);
     
    551551psMetadataItem* psMetadataGet(
    552552    const psMetadata* md,              ///< Metadata collection to retrieve metadata item.
    553     long location                      ///< Index number, PS_LIST_HEAD, or PS_LIST_TAIL
     553    int location                      ///< Index number, PS_LIST_HEAD, or PS_LIST_TAIL
    554554);
    555555
  • trunk/psLib/src/types/psMetadataConfig.c

    r4556 r4589  
    1010*  @author Eric Van Alst, MHPCC
    1111*
    12 *  @version $Revision: 1.36 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2005-07-15 02:33:54 $
     12*  @version $Revision: 1.37 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2005-07-21 01:40:10 $
    1414*
    1515*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    8686;
    8787static void parseLevelInfoFree(p_psParseLevelInfo* info);
    88 static psBool parseLine(psS32* level,   psArray* levelArray,
    89                         char*  linePtr, psS32 lineCount,     char* fileName, psBool overwrite);
    90 static psBool parseMetadataItem(char* keyName, psS32* level,     psArray* levelArray,
    91                                 char* linePtr, psS32  lineCount, char*    fileName,    psMetadataFlags flags);
    92 
     88static psBool parseLine(psS32* level,   psArray* levelArray, char*  linePtr, psS32 lineCount,
     89                        char* fileName, psBool overwrite);
     90static psBool parseMetadataItem(char* keyName, psS32* level, psArray* levelArray, char* linePtr,
     91                                psS32 lineCount, char* fileName, psMetadataFlags flags);
    9392static void parseLevelInfoFree(p_psParseLevelInfo* info)
    9493{
     
    117116//  Removes leading and trailing whitespace and # characters from a string. The cleaned string is a new null
    118117//  terminated copy of the original input string.
    119 static char *cleanString(char *inString, psS32 sLen, psBool ignoreComment)
     118static char *cleanString(char *inString,
     119                         psS32 sLen,
     120                         psBool ignoreComment)
    120121{
    121122    char *ptrB = NULL;
     
    163164
    164165// Count repeat occurances of a single character within a line. The input string must be null terminated.
    165 static psS32 repeatedChars(char *inString, char ch)
     166static psS32 repeatedChars(char *inString,
     167                           char ch)
    166168{
    167169    psS32 count = 0;
     
    179181// Returns cleaned token based on delimiter, but not including delimiter. Also changes the pointer location
    180182// the beginning of the string. Tokens are newly allocated null terminated strings.
    181 static char* getToken(char **inString, char *delimiter, psS32 *status, psBool ignoreComment)
     183static char* getToken(char **inString,
     184                      char *delimiter,
     185                      psS32 *status,
     186                      psBool ignoreComment)
    182187{
    183188    char *cleanToken = NULL;
     
    213218// Returns single parsed value as a double precision number. The input string must be cleaned and null
    214219// terminated.
    215 static double parseValue(char *inString, psS32 *status)
     220static double parseValue(char *inString,
     221                         psS32 *status)
    216222{
    217223    char *end = NULL;
     
    229235
    230236/** Returns true or false. 'T', 't', '1', 'F', 'f', and '0' are acceptable, parsable variations. */
    231 static psBool parseBool(char *inString, psS32 *status)
     237static psBool parseBool(char *inString,
     238                        psS32 *status)
    232239{
    233240    psBool value = false;
     
    246253
    247254/** Returns parsed vector filled with with data. The input string must be null terminated. */
    248 static psVector* parseVector(char *inString, psElemType elemType, psS32 *status)
     255static psVector* parseVector(char *inString,
     256                             psElemType elemType,
     257                             psS32 *status)
    249258{
    250259    char*      end       = NULL;
     
    363372}
    364373
    365 bool psMetadataItemPrint(FILE * fd, const char *format, const psMetadataItem* item)
     374bool psMetadataItemPrint(FILE * fd,
     375                         const char *format,
     376                         const psMetadataItem* item)
    366377{
    367378    psMetadataType type;
     
    453464
    454465
    455 psMetadata* psMetadataReadHeader(psMetadata* output, char *extName, psS32 extNum, char *fileName)
     466psMetadata* psMetadataReadHeader(psMetadata* output,
     467                                 char *extName,
     468                                 psS32 extNum,
     469                                 char *fileName)
    456470{
    457471    psBool tempBool;
     
    604618}
    605619
    606 static psMetadata* setMetadataItem(psMetadata* template, char* linePtr)
     620static psMetadata* setMetadataItem(psMetadata* template,
     621                                   char* linePtr)
    607622{
    608623    psMetadata*      md           = NULL;
     
    674689}
    675690
    676 psBool parseMetadataItem(char* keyName, psS32* level,     psArray* levelArray,
    677                          char* linePtr, psS32  lineCount, char*    fileName,   psMetadataFlags flags)
     691psBool parseMetadataItem(char* keyName,
     692                         psS32* level,
     693                         psArray* levelArray,
     694                         char* linePtr,
     695                         psS32 lineCount,
     696                         char* fileName,
     697                         psMetadataFlags flags)
    678698{
    679699    psBool               returnValue   = true;
     
    940960}
    941961
    942 psBool parseLine(psS32* level,     psArray* levelArray, char*  linePtr,
    943                  psS32  lineCount, char*    fileName,   psBool overwrite)
     962psBool parseLine(psS32* level,
     963                 psArray* levelArray,
     964                 char* linePtr,
     965                 psS32 lineCount,
     966                 char* fileName,
     967                 psBool overwrite)
    944968{
    945969    psBool              returnValue    = true;
     
    10751099}
    10761100
    1077 psMetadata* psMetadataConfigParse(psMetadata* md, unsigned int *nFail, const char *fileName, bool overwrite)
     1101psMetadata* psMetadataConfigParse(psMetadata* md,
     1102                                  unsigned int *nFail,
     1103                                  const char *filename,
     1104                                  bool overwrite)
    10781105{
    10791106    FILE*               fp                   = NULL;
     
    10861113
    10871114    // Check for NULL file name
    1088     PS_ASSERT_PTR_NON_NULL(fileName,NULL);
     1115    PS_ASSERT_PTR_NON_NULL(filename,NULL);
    10891116
    10901117    // Check for NULL nFail
     
    10921119
    10931120    // Attempt to open specified file
    1094     if((fp=fopen(fileName, "r")) == NULL) {
    1095         psError(PS_ERR_IO, true, PS_ERRORTEXT_psMetadataIO_FILE_OPEN_FAILED, fileName);
     1121    if((fp=fopen(filename, "r")) == NULL) {
     1122        psError(PS_ERR_IO, true, PS_ERRORTEXT_psMetadataIO_FILE_OPEN_FAILED, filename);
    10961123        return NULL;
    10971124    }
     
    11221149        lineCount++;
    11231150
    1124         if(!parseLine(&nestingLevel,parseLevelInfoArray,linePtr,lineCount,(char*)fileName,overwrite)) {
     1151        if(!parseLine(&nestingLevel,parseLevelInfoArray,linePtr,lineCount,(char*)filename,overwrite)) {
    11251152            (*nFail)++;
    11261153        }
  • trunk/psLib/src/types/psMetadataConfig.h

    r4556 r4589  
    1010 *  @author Robert DeSonia, MHPCC
    1111 *
    12  *  @version $Revision: 1.17 $ $Name: not supported by cvs2svn $
    13  *  @date $Date: 2005-07-15 02:33:54 $
     12 *  @version $Revision: 1.18 $ $Name: not supported by cvs2svn $
     13 *  @date $Date: 2005-07-21 01:40:10 $
    1414 *
    1515 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    8282    psMetadata* md,                    ///< Resulting metadata from read.
    8383    unsigned int *nFail,               ///< Number of failed lines.
    84     const char *fileName,              ///< Name of file to read.
     84    const char *filename,              ///< Name of file to read.
    8585    bool overwrite                     ///< Allow overwrite of duplicate specifications.
    8686);
  • trunk/psLib/test/math/tst_psMatrix04.c

    r4547 r4589  
    1313 *  @author  Ross Harman, MHPCC
    1414 *
    15  *  @version $Revision: 1.1 $  $Name: not supported by cvs2svn $
    16  *  @date  $Date: 2005-07-13 02:47:00 $
     15 *  @version $Revision: 1.2 $  $Name: not supported by cvs2svn $
     16 *  @date  $Date: 2005-07-21 01:40:10 $
    1717 *
    1818 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    5151{
    5252    float det = 0.0f;
    53     float *det2 = NULL;
     53    float det2 = 0;
    5454    psImage *outImage = NULL;
    5555    psImage *inImage = NULL;
     
    120120    printPositiveTestHeader(stdout, "psMatrix", "Calculate determinant only");
    121121    det2 = psMatrixDeterminant(inImage);
    122     CHECK_VALUE(*det2);
    123     psFree(det2);
     122    CHECK_VALUE(det2);
    124123    det2 = psMatrixDeterminant(inImage32);
    125     CHECK_VALUE(*det2);
    126     psFree(det2);
     124    CHECK_VALUE(det2);
    127125    printFooter(stdout, "psMatrix", "Calculate determinant only", true);
    128126
  • trunk/psLib/test/types/verified/tst_psLookupTable_01.stderr

    r4547 r4589  
    88    Following should generate error message for invalid file name
    99<DATE><TIME>|<HOST>|E|psLookupTableAlloc (FILE:LINENO)
    10     Unallowable operation: fileName is NULL.
     10    Unallowable operation: filename is NULL.
    1111<DATE><TIME>|<HOST>|I|testLookupTableAlloc
    1212    Following should generate error message for invalid format string
  • trunk/psLib/test/types/verified/tst_psMetadataIO.stderr

    r4547 r4589  
    6565    Following should generate an error message for NULL file name arg
    6666<DATE><TIME>|<HOST>|E|psMetadataConfigParse (FILE:LINENO)
    67     Unallowable operation: fileName is NULL.
     67    Unallowable operation: filename is NULL.
    6868
    6969---> TESTPOINT PASSED (psMetadataConfigParse{psMetadataConfigParse} | tst_psMetadataIO.c)
Note: See TracChangeset for help on using the changeset viewer.