IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 4293


Ignore:
Timestamp:
Jun 16, 2005, 2:11:08 PM (21 years ago)
Author:
drobbin
Message:

* empty log message *

Location:
trunk/psLib/src
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/astro/psTime.h

    r4162 r4293  
    1111 *  @author Ross Harman, MHPCC
    1212 *
    13  *  @version $Revision: 1.30 $ $Name: not supported by cvs2svn $
    14  *  @date $Date: 2005-06-08 23:40:45 $
     13 *  @version $Revision: 1.31 $ $Name: not supported by cvs2svn $
     14 *  @date $Date: 2005-06-17 00:10:59 $
    1515 *
    1616 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    7676 * @return  bool: True for success, false for failure.
    7777 */
    78 psBool p_psTimeInit(const char *fileName);
     78psBool p_psTimeInit(
     79    const char *fileName               ///< File name containing config/data info
     80);
    7981
    8082/** Free memory persistant time data.
  • trunk/psLib/src/astronomy/psTime.h

    r4162 r4293  
    1111 *  @author Ross Harman, MHPCC
    1212 *
    13  *  @version $Revision: 1.30 $ $Name: not supported by cvs2svn $
    14  *  @date $Date: 2005-06-08 23:40:45 $
     13 *  @version $Revision: 1.31 $ $Name: not supported by cvs2svn $
     14 *  @date $Date: 2005-06-17 00:10:59 $
    1515 *
    1616 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    7676 * @return  bool: True for success, false for failure.
    7777 */
    78 psBool p_psTimeInit(const char *fileName);
     78psBool p_psTimeInit(
     79    const char *fileName               ///< File name containing config/data info
     80);
    7981
    8082/** Free memory persistant time data.
  • trunk/psLib/src/collections/psPixels.h

    r4214 r4293  
    77 *  @author Robert DeSonia, MHPCC
    88 *
    9  *  @version $Revision: 1.5 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2005-06-11 02:19:05 $
     9 *  @version $Revision: 1.6 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2005-06-17 00:11:02 $
    1111 *
    1212 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    2121/// @{
    2222
     23/** Data structure for storing psPixel coordinates  */
    2324typedef struct
    2425{
    25     psS32 x;
    26     psS32 y;
     26    psS32 x;                           ///< x coordinate
     27    psS32 y;                           ///< y coordinate
    2728}
    2829psPixelCoord;
     
    3233 *  Usually an image mask is the best way to carry information about what
    3334 *  pixels mean what. However, in the case where the number of pixels in which
    34  *  we are interested is limited, it is more efficient to simply carry a list
     35 *  we are interested is limited, it is more efficient to simply carry a list
    3536 *  of pixels. An example of this is in the image combination code, where we
    3637 *  want to perform an operation on a relatively small fraction of pixels, and
    37  *  it is inefficient to go through an entire mask image checking each pixel.
     38 *  it is inefficient to go through an entire mask image checking each pixel.
    3839 *
    3940 */
    4041typedef struct
    4142{
    42     int n;
    43     int nalloc;
    44     psPixelCoord* data;
     43    int n;                             ///< Number in usa
     44    int nalloc;                        ///< Number allocated
     45    psPixelCoord* data;                ///< The pixel coordinates
    4546}
    4647psPixels;
     
    136137);
    137138
    138 /** Prints a psPixels to specified destination. */
     139/** Prints a psPixels to specified destination.
     140 * 
     141 *  @return bool:    True if successful.
     142*/
    139143bool p_psPixelsPrint(
    140     FILE *fd,
    141     psPixels* pixels,
    142     const char *name
     144    FILE *fd,                          ///< destination file descriptor
     145    psPixels* pixels,                  ///< psPixels to print
     146    const char *name                   ///< printf-style format of header line
    143147);
    144148
  • trunk/psLib/src/dataManip/psRandom.h

    r4162 r4293  
    1010*  @author GLG, MHPCC
    1111*
    12 *  @version $Revision: 1.4 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2005-06-08 23:40:45 $
     12*  @version $Revision: 1.5 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2005-06-17 00:11:05 $
    1414*
    1515*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    3333 */
    3434
     35/** Enumeration containing a flag for psRandom types.  */
    3536typedef enum {
    36     PS_RANDOM_TAUS    ///< A maximally equidistributed combined Tausworthe generator.
     37    PS_RANDOM_TAUS                     ///< A maximally equidistributed combined Tausworthe generator.
    3738} psRandomType;
    3839
     40/** Data structure for psRandom.
     41 *  Contains information on the psRandom type and GNU Scientific Library random number generator.
     42 */
    3943typedef struct
    4044{
    41     psRandomType type; ///< The type of RNG
    42     gsl_rng *gsl; ///< The RNG itself
     45    psRandomType type;                 ///< The type of RNG
     46    gsl_rng *gsl;                      ///< The RNG itself
    4347}
    4448psRandom;
    4549
    46 psRandom *psRandomAlloc(psRandomType type,
    47                         psU64 seed);
     50/** Allocates a psRandom struct.
     51 * 
     52 *  @return psRandom*:    A new psRandom structure.
     53 */
     54psRandom *psRandomAlloc(
     55    psRandomType type,                 ///< The type of RNG
     56    psU64 seed                         ///< Known value with which to seed the RNG
     57);
    4858
    49 void psRandomReset(psRandom *rand,
    50                    psU64 seed);
     59/** Resets an existing psRandom struct.
     60 * 
     61 *  @return void
     62 */
     63void psRandomReset(
     64    psRandom *rand,                    ///< Existing psRandom struct to reset
     65    psU64 seed                         ///< Known value with which to seed the RNG
     66);
    5167
    52 psF64 psRandomUniform(const psRandom *r);
    53 psF64 psRandomGaussian(const psRandom *r);
    54 psF64 psRandomPoisson(const psRandom *r, psF64 mean);
     68/** Random number generator based on a uniform distribution on [0,1).
     69 *  Uses gsl_rng_uniform.
     70 * 
     71 *  @return psF64:     Random number.
     72 */
     73psF64 psRandomUniform(
     74    const psRandom *r                  ///< psRandom struct for RNG
     75);
     76
     77/** Random number generator based on a Gaussian deviate, N(0,1).
     78 *  Uses gsl_ran_gaussian.
     79 * 
     80 *  @return psF64:     Random number.
     81 */
     82psF64 psRandomGaussian(
     83    const psRandom *r                  ///< psRandom struct for RNG
     84);
     85
     86/** Random number generator based on a Poisson distribution with the given mean.
     87 *  Uses gsl_ran_poisson.
     88 * 
     89 *  @return psF64:     Random number.
     90 */
     91psF64 psRandomPoisson(
     92    const psRandom *r,                 ///< psRandom struct for RNG
     93    psF64 mean                         ///< Mean value
     94);
    5595
    5696/* \} */// End of MathGroup Functions
  • trunk/psLib/src/dataManip/psStats.h

    r4162 r4293  
    1414 *  @author GLG, MHPCC
    1515 *
    16  *  @version $Revision: 1.42 $ $Name: not supported by cvs2svn $
    17  *  @date $Date: 2005-06-08 23:40:45 $
     16 *  @version $Revision: 1.43 $ $Name: not supported by cvs2svn $
     17 *  @date $Date: 2005-06-17 00:11:05 $
    1818 *
    1919 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    3737// XXX: Is PS_STAT_ROBUST_FOR_SAMPLE obsolete?
    3838typedef enum {
    39     PS_STAT_SAMPLE_MEAN = 0x000001,
    40     PS_STAT_SAMPLE_MEDIAN = 0x000002,
    41     PS_STAT_SAMPLE_STDEV = 0x000004,
    42     PS_STAT_SAMPLE_QUARTILE = 0x000008,
    43     PS_STAT_ROBUST_MEAN = 0x000010,
    44     PS_STAT_ROBUST_MEDIAN = 0x000020,
    45     PS_STAT_ROBUST_MODE = 0x000040,
    46     PS_STAT_ROBUST_STDEV = 0x000080,
    47     PS_STAT_ROBUST_QUARTILE = 0x000100,
    48     PS_STAT_CLIPPED_MEAN = 0x000200,
    49     PS_STAT_CLIPPED_STDEV = 0x000400,
    50     PS_STAT_MAX =  0x000800,
    51     PS_STAT_MIN =  0x001000,
    52     PS_STAT_USE_RANGE =  0x002000,
    53     PS_STAT_USE_BINSIZE = 0x004000,
    54     PS_STAT_ROBUST_FOR_SAMPLE = 0x008000
     39    PS_STAT_SAMPLE_MEAN = 0x000001,         ///< Sample Mean
     40    PS_STAT_SAMPLE_MEDIAN = 0x000002,       ///< Sample Median
     41    PS_STAT_SAMPLE_STDEV = 0x000004,        ///< Sample Standard Deviation
     42    PS_STAT_SAMPLE_QUARTILE = 0x000008,     ///< Sample Quartile
     43    PS_STAT_ROBUST_MEAN = 0x000010,         ///< Robust Mean
     44    PS_STAT_ROBUST_MEDIAN = 0x000020,       ///< Robust Median
     45    PS_STAT_ROBUST_MODE = 0x000040,         ///< Robust Mode
     46    PS_STAT_ROBUST_STDEV = 0x000080,        ///< Robust Standarad Deviation
     47    PS_STAT_ROBUST_QUARTILE = 0x000100,     ///< Robust Quartile
     48    PS_STAT_CLIPPED_MEAN = 0x000200,        ///< Clipped Mean
     49    PS_STAT_CLIPPED_STDEV = 0x000400,       ///< Clipped Standard Deviation
     50    PS_STAT_MAX =  0x000800,                ///< Maximum
     51    PS_STAT_MIN =  0x001000,                ///< Minumum
     52    PS_STAT_USE_RANGE =  0x002000,          ///< Range
     53    PS_STAT_USE_BINSIZE = 0x004000,         ///< Binsize
     54    PS_STAT_ROBUST_FOR_SAMPLE = 0x008000    ///< Robust for sample
    5555} psStatsOptions;
    5656
     
    180180// XXX: Create a single, generic, version of the vector normalize function.
    181181// XXX: Ask IfA for a public psLib function.
    182 void p_psNormalizeVectorRangeU8(psVector* myData, psU8 low, psU8 high);
    183 void p_psNormalizeVectorRangeU16(psVector* myData, psU16 low, psU16 high);
    184 void p_psNormalizeVectorRangeU32(psVector* myData, psU32 low, psU32 high);
    185 void p_psNormalizeVectorRangeU64(psVector* myData, psU64 low, psU64 high);
    186 void p_psNormalizeVectorRangeS8(psVector* myData, psS8 low, psS8 high);
    187 void p_psNormalizeVectorRangeS16(psVector* myData, psS16 low, psS16 high);
    188 void p_psNormalizeVectorRangeS32(psVector* myData, psS32 low, psS32 high);
    189 void p_psNormalizeVectorRangeS64(psVector* myData, psS64 low, psS64 high);
    190 void p_psNormalizeVectorRangeF32(psVector* myData, psF32 low, psF32 high);
    191 void p_psNormalizeVectorRangeF64(psVector* myData, psF64 low, psF64 high);
     182
     183/** Normalize the range of a vector containing U8 values  */
     184void p_psNormalizeVectorRangeU8(
     185    psVector* myData,                  ///< Vector containing the U8 values
     186    psU8 low,                          ///< Minimum value
     187    psU8 high                          ///< Maximum value
     188);
     189
     190/** Normalize the range of a vector containing U16 values  */
     191void p_psNormalizeVectorRangeU16(
     192    psVector* myData,                  ///< Vector containing the U16 values
     193    psU16 low,                         ///< Minimum value
     194    psU16 high                         ///< Maximum value
     195);
     196
     197/** Normalize the range of a vector containing U32 values  */
     198void p_psNormalizeVectorRangeU32(
     199    psVector* myData,                  ///< Vector containing the U32 values
     200    psU32 low,                         ///< Minimum value
     201    psU32 high                         ///< Maximum value
     202);
     203
     204/** Normalize the range of a vector containing U64 values  */
     205void p_psNormalizeVectorRangeU64(
     206    psVector* myData,                  ///< Vector containing the U64 values
     207    psU64 low,                         ///< Minimum value
     208    psU64 high                         ///< Maximum value
     209);
     210
     211/** Normalize the range of a vector containing S8 values  */
     212void p_psNormalizeVectorRangeS8(
     213    psVector* myData,                  ///< Vector containing the S8 values
     214    psS8 low,                          ///< Minimum value
     215    psS8 high                          ///< Maximum value
     216);
     217
     218/** Normalize the range of a vector containing S16 values  */
     219void p_psNormalizeVectorRangeS16(
     220    psVector* myData,                  ///< Vector containing the S16 values
     221    psS16 low,                         ///< Minimum value
     222    psS16 high                         ///< Maximum value
     223);
     224
     225/** Normalize the range of a vector containing S32 values  */
     226void p_psNormalizeVectorRangeS32(
     227    psVector* myData,                  ///< Vector containing the S32 values
     228    psS32 low,                         ///< Minimum value
     229    psS32 high                         ///< Maximum value
     230);
     231
     232/** Normalize the range of a vector containing S64 values  */
     233void p_psNormalizeVectorRangeS64(
     234    psVector* myData,                  ///< Vector containing the S64 values
     235    psS64 low,                         ///< Minimum value
     236    psS64 high                         ///< Maximum value
     237);
     238
     239/** Normalize the range of a vector containing F32 values  */
     240void p_psNormalizeVectorRangeF32(
     241    psVector* myData,                  ///< Vector containing the F32 values
     242    psF32 low,                         ///< Minimum value
     243    psF32 high                         ///< Maximum value
     244);
     245
     246/** Normalize the range of a vector containing F64 values  */
     247void p_psNormalizeVectorRangeF64(
     248    psVector* myData,                  ///< Vector containing the F64 values
     249    psF64 low,                         ///< Minimum value
     250    psF64 high                         ///< Maximum value
     251);
    192252
    193253/// @}
  • trunk/psLib/src/math/psRandom.h

    r4162 r4293  
    1010*  @author GLG, MHPCC
    1111*
    12 *  @version $Revision: 1.4 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2005-06-08 23:40:45 $
     12*  @version $Revision: 1.5 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2005-06-17 00:11:05 $
    1414*
    1515*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    3333 */
    3434
     35/** Enumeration containing a flag for psRandom types.  */
    3536typedef enum {
    36     PS_RANDOM_TAUS    ///< A maximally equidistributed combined Tausworthe generator.
     37    PS_RANDOM_TAUS                     ///< A maximally equidistributed combined Tausworthe generator.
    3738} psRandomType;
    3839
     40/** Data structure for psRandom.
     41 *  Contains information on the psRandom type and GNU Scientific Library random number generator.
     42 */
    3943typedef struct
    4044{
    41     psRandomType type; ///< The type of RNG
    42     gsl_rng *gsl; ///< The RNG itself
     45    psRandomType type;                 ///< The type of RNG
     46    gsl_rng *gsl;                      ///< The RNG itself
    4347}
    4448psRandom;
    4549
    46 psRandom *psRandomAlloc(psRandomType type,
    47                         psU64 seed);
     50/** Allocates a psRandom struct.
     51 * 
     52 *  @return psRandom*:    A new psRandom structure.
     53 */
     54psRandom *psRandomAlloc(
     55    psRandomType type,                 ///< The type of RNG
     56    psU64 seed                         ///< Known value with which to seed the RNG
     57);
    4858
    49 void psRandomReset(psRandom *rand,
    50                    psU64 seed);
     59/** Resets an existing psRandom struct.
     60 * 
     61 *  @return void
     62 */
     63void psRandomReset(
     64    psRandom *rand,                    ///< Existing psRandom struct to reset
     65    psU64 seed                         ///< Known value with which to seed the RNG
     66);
    5167
    52 psF64 psRandomUniform(const psRandom *r);
    53 psF64 psRandomGaussian(const psRandom *r);
    54 psF64 psRandomPoisson(const psRandom *r, psF64 mean);
     68/** Random number generator based on a uniform distribution on [0,1).
     69 *  Uses gsl_rng_uniform.
     70 * 
     71 *  @return psF64:     Random number.
     72 */
     73psF64 psRandomUniform(
     74    const psRandom *r                  ///< psRandom struct for RNG
     75);
     76
     77/** Random number generator based on a Gaussian deviate, N(0,1).
     78 *  Uses gsl_ran_gaussian.
     79 * 
     80 *  @return psF64:     Random number.
     81 */
     82psF64 psRandomGaussian(
     83    const psRandom *r                  ///< psRandom struct for RNG
     84);
     85
     86/** Random number generator based on a Poisson distribution with the given mean.
     87 *  Uses gsl_ran_poisson.
     88 * 
     89 *  @return psF64:     Random number.
     90 */
     91psF64 psRandomPoisson(
     92    const psRandom *r,                 ///< psRandom struct for RNG
     93    psF64 mean                         ///< Mean value
     94);
    5595
    5696/* \} */// End of MathGroup Functions
  • trunk/psLib/src/math/psStats.h

    r4162 r4293  
    1414 *  @author GLG, MHPCC
    1515 *
    16  *  @version $Revision: 1.42 $ $Name: not supported by cvs2svn $
    17  *  @date $Date: 2005-06-08 23:40:45 $
     16 *  @version $Revision: 1.43 $ $Name: not supported by cvs2svn $
     17 *  @date $Date: 2005-06-17 00:11:05 $
    1818 *
    1919 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    3737// XXX: Is PS_STAT_ROBUST_FOR_SAMPLE obsolete?
    3838typedef enum {
    39     PS_STAT_SAMPLE_MEAN = 0x000001,
    40     PS_STAT_SAMPLE_MEDIAN = 0x000002,
    41     PS_STAT_SAMPLE_STDEV = 0x000004,
    42     PS_STAT_SAMPLE_QUARTILE = 0x000008,
    43     PS_STAT_ROBUST_MEAN = 0x000010,
    44     PS_STAT_ROBUST_MEDIAN = 0x000020,
    45     PS_STAT_ROBUST_MODE = 0x000040,
    46     PS_STAT_ROBUST_STDEV = 0x000080,
    47     PS_STAT_ROBUST_QUARTILE = 0x000100,
    48     PS_STAT_CLIPPED_MEAN = 0x000200,
    49     PS_STAT_CLIPPED_STDEV = 0x000400,
    50     PS_STAT_MAX =  0x000800,
    51     PS_STAT_MIN =  0x001000,
    52     PS_STAT_USE_RANGE =  0x002000,
    53     PS_STAT_USE_BINSIZE = 0x004000,
    54     PS_STAT_ROBUST_FOR_SAMPLE = 0x008000
     39    PS_STAT_SAMPLE_MEAN = 0x000001,         ///< Sample Mean
     40    PS_STAT_SAMPLE_MEDIAN = 0x000002,       ///< Sample Median
     41    PS_STAT_SAMPLE_STDEV = 0x000004,        ///< Sample Standard Deviation
     42    PS_STAT_SAMPLE_QUARTILE = 0x000008,     ///< Sample Quartile
     43    PS_STAT_ROBUST_MEAN = 0x000010,         ///< Robust Mean
     44    PS_STAT_ROBUST_MEDIAN = 0x000020,       ///< Robust Median
     45    PS_STAT_ROBUST_MODE = 0x000040,         ///< Robust Mode
     46    PS_STAT_ROBUST_STDEV = 0x000080,        ///< Robust Standarad Deviation
     47    PS_STAT_ROBUST_QUARTILE = 0x000100,     ///< Robust Quartile
     48    PS_STAT_CLIPPED_MEAN = 0x000200,        ///< Clipped Mean
     49    PS_STAT_CLIPPED_STDEV = 0x000400,       ///< Clipped Standard Deviation
     50    PS_STAT_MAX =  0x000800,                ///< Maximum
     51    PS_STAT_MIN =  0x001000,                ///< Minumum
     52    PS_STAT_USE_RANGE =  0x002000,          ///< Range
     53    PS_STAT_USE_BINSIZE = 0x004000,         ///< Binsize
     54    PS_STAT_ROBUST_FOR_SAMPLE = 0x008000    ///< Robust for sample
    5555} psStatsOptions;
    5656
     
    180180// XXX: Create a single, generic, version of the vector normalize function.
    181181// XXX: Ask IfA for a public psLib function.
    182 void p_psNormalizeVectorRangeU8(psVector* myData, psU8 low, psU8 high);
    183 void p_psNormalizeVectorRangeU16(psVector* myData, psU16 low, psU16 high);
    184 void p_psNormalizeVectorRangeU32(psVector* myData, psU32 low, psU32 high);
    185 void p_psNormalizeVectorRangeU64(psVector* myData, psU64 low, psU64 high);
    186 void p_psNormalizeVectorRangeS8(psVector* myData, psS8 low, psS8 high);
    187 void p_psNormalizeVectorRangeS16(psVector* myData, psS16 low, psS16 high);
    188 void p_psNormalizeVectorRangeS32(psVector* myData, psS32 low, psS32 high);
    189 void p_psNormalizeVectorRangeS64(psVector* myData, psS64 low, psS64 high);
    190 void p_psNormalizeVectorRangeF32(psVector* myData, psF32 low, psF32 high);
    191 void p_psNormalizeVectorRangeF64(psVector* myData, psF64 low, psF64 high);
     182
     183/** Normalize the range of a vector containing U8 values  */
     184void p_psNormalizeVectorRangeU8(
     185    psVector* myData,                  ///< Vector containing the U8 values
     186    psU8 low,                          ///< Minimum value
     187    psU8 high                          ///< Maximum value
     188);
     189
     190/** Normalize the range of a vector containing U16 values  */
     191void p_psNormalizeVectorRangeU16(
     192    psVector* myData,                  ///< Vector containing the U16 values
     193    psU16 low,                         ///< Minimum value
     194    psU16 high                         ///< Maximum value
     195);
     196
     197/** Normalize the range of a vector containing U32 values  */
     198void p_psNormalizeVectorRangeU32(
     199    psVector* myData,                  ///< Vector containing the U32 values
     200    psU32 low,                         ///< Minimum value
     201    psU32 high                         ///< Maximum value
     202);
     203
     204/** Normalize the range of a vector containing U64 values  */
     205void p_psNormalizeVectorRangeU64(
     206    psVector* myData,                  ///< Vector containing the U64 values
     207    psU64 low,                         ///< Minimum value
     208    psU64 high                         ///< Maximum value
     209);
     210
     211/** Normalize the range of a vector containing S8 values  */
     212void p_psNormalizeVectorRangeS8(
     213    psVector* myData,                  ///< Vector containing the S8 values
     214    psS8 low,                          ///< Minimum value
     215    psS8 high                          ///< Maximum value
     216);
     217
     218/** Normalize the range of a vector containing S16 values  */
     219void p_psNormalizeVectorRangeS16(
     220    psVector* myData,                  ///< Vector containing the S16 values
     221    psS16 low,                         ///< Minimum value
     222    psS16 high                         ///< Maximum value
     223);
     224
     225/** Normalize the range of a vector containing S32 values  */
     226void p_psNormalizeVectorRangeS32(
     227    psVector* myData,                  ///< Vector containing the S32 values
     228    psS32 low,                         ///< Minimum value
     229    psS32 high                         ///< Maximum value
     230);
     231
     232/** Normalize the range of a vector containing S64 values  */
     233void p_psNormalizeVectorRangeS64(
     234    psVector* myData,                  ///< Vector containing the S64 values
     235    psS64 low,                         ///< Minimum value
     236    psS64 high                         ///< Maximum value
     237);
     238
     239/** Normalize the range of a vector containing F32 values  */
     240void p_psNormalizeVectorRangeF32(
     241    psVector* myData,                  ///< Vector containing the F32 values
     242    psF32 low,                         ///< Minimum value
     243    psF32 high                         ///< Maximum value
     244);
     245
     246/** Normalize the range of a vector containing F64 values  */
     247void p_psNormalizeVectorRangeF64(
     248    psVector* myData,                  ///< Vector containing the F64 values
     249    psF64 low,                         ///< Minimum value
     250    psF64 high                         ///< Maximum value
     251);
    192252
    193253/// @}
  • trunk/psLib/src/psTest.h

    r4162 r4293  
    55 *  @author Robert DeSonia, MHPCC
    66 *
    7  *  @version $Revision: 1.3 $ $Name: not supported by cvs2svn $
    8  *  @date $Date: 2005-06-08 23:40:45 $
     7 *  @version $Revision: 1.4 $ $Name: not supported by cvs2svn $
     8 *  @date $Date: 2005-06-17 00:10:55 $
    99 *
    1010 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    2929p_printFooter(filePtr, __FILE__, packageName, testPointName, success)
    3030
     31/** Specifies the format of a user-defined function for use with psTest functions. */
    3132typedef psS32 (*testFcn)(void);
    3233
     34/** Defines a data structure containing test description information. */
    3335typedef struct
    3436{
    35     testFcn     fcn;
    36     psS32       testPointNumber;
    37     const char* testPointName;
    38     psS32       expectedReturn;
    39     psBool      isDuplicateEntry;
     37    testFcn     fcn;                   ///< Specified test function
     38    psS32       testPointNumber;       ///< Test Point Number
     39    const char* testPointName;         ///< Test Point Name
     40    psS32       expectedReturn;        ///< Expected return value
     41    psBool      isDuplicateEntry;      ///< Is the entry a duplicate?
    4042}
    4143testDescription;
     
    5052/////////////////////////// PRIVATE FUNCTIONS //////////////////////////////
    5153
     54///XXX: Comments correct?
     55
     56/** Procedure used to run a test.
     57 * 
     58 *  @return psBool:    True if successful.
     59 */
    5260psBool p_runTest(
    53     FILE *fp,
    54     const char* testPointFile,
    55     const char* packageName,
    56     const char* testPointName,
    57     testFcn fcn,
    58     psS32 expectedReturn,
    59     psBool useFork
     61    FILE *fp,                          ///< File to test
     62    const char* testPointFile,         ///< Test point in file
     63    const char* packageName,           ///< Package name
     64    const char* testPointName,         ///< Test point name
     65    testFcn fcn,                       ///< Function tested
     66    psS32 expectedReturn,              ///< Expected return
     67    psBool useFork                     ///< Fork to use
    6068);
    6169
     70/** Procedure used to run the test suite.
     71 * 
     72 *  @return psBool:    True if successful.
     73 */
    6274psBool p_runTestSuite(
    63     FILE *fp,
    64     const char* testPointFile,
    65     const char* packageName,
    66     testDescription tests[],
    67     psS32 argc,
    68     char * const argv[]
     75    FILE *fp,                          ///< File to test
     76    const char* testPointFile,         ///< Test point in file
     77    const char* packageName,           ///< Package name
     78    testDescription tests[],           ///< Description of tests
     79    psS32 argc,                        ///< Number of test arguments
     80    char * const argv[]                ///< Test arguments
    6981);
    7082
     83/** Prints a positive test header to file */
    7184void p_printPositiveTestHeader(
    72     FILE *fp,
    73     const char* testPointFile,
    74     const char* packageName,
    75     const char* testPointName
     85    FILE *fp,                          ///< File to which to print
     86    const char* testPointFile,         ///< Test point in file
     87    const char* packageName,           ///< Package name
     88    const char* testPointName          ///< Test point name
    7689);
    7790
     91/** Prints a negative test header to file */
    7892void p_printNegativeTestHeader(
    79     FILE *fp,
    80     const char* testPointFile,
    81     const char* packageName,
    82     const char* testPointName,
    83     const char* expectedError,
    84     psS32 exitValue
     93    FILE *fp,                          ///< File to which to print
     94    const char* testPointFile,         ///< Test point in file
     95    const char* packageName,           ///< Package name
     96    const char* testPointName,         ///< Test point name
     97    const char* expectedError,         ///< Expected error
     98    psS32 exitValue                    ///< Exit value
    8599);
    86100
     101/** Prints a footer to file */
    87102void p_printFooter(
    88     FILE *fp,
    89     const char* testPointFile,
    90     const char* packageName,
    91     const char* testPointName,
    92     psBool success
     103    FILE *fp,                          ///< File to which to print
     104    const char* testPointFile,         ///< Test point in file
     105    const char* packageName,           ///< Package name
     106    const char* testPointName,         ///< Test point name
     107    psBool success                     ///< True if successful
    93108);
    94109
  • trunk/psLib/src/sys/psType.h

    r4162 r4293  
    1010*  @author Ross Harman, MHPCC
    1111*
    12 *  @version $Revision: 1.33 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2005-06-08 23:40:45 $
     12*  @version $Revision: 1.34 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2005-06-17 00:11:08 $
    1414*
    1515*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    5252
    5353#ifdef SWIG
     54/** 32-bit complex value */
    5455typedef struct
    5556{
     
    5758}
    5859psC32;
     60
     61/** 64-bit complex value */
    5962typedef struct
    6063{
     
    6265}
    6366psC64;
     67
    6468#else // SWIG
    6569typedef float _Complex psC32;          ///< complex with 32-bit floating point Real and Imagary numbers
     
    7074typedef bool psBool;                   ///< boolean value
    7175
     76/** Enumeration of data types for function elements.
     77 *  Contains replacements for native types.
     78 */
    7279typedef enum {
    7380    PS_TYPE_S8   = 0x0101,             ///< Character.
  • trunk/psLib/src/sysUtils/psType.h

    r4162 r4293  
    1010*  @author Ross Harman, MHPCC
    1111*
    12 *  @version $Revision: 1.33 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2005-06-08 23:40:45 $
     12*  @version $Revision: 1.34 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2005-06-17 00:11:08 $
    1414*
    1515*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    5252
    5353#ifdef SWIG
     54/** 32-bit complex value */
    5455typedef struct
    5556{
     
    5758}
    5859psC32;
     60
     61/** 64-bit complex value */
    5962typedef struct
    6063{
     
    6265}
    6366psC64;
     67
    6468#else // SWIG
    6569typedef float _Complex psC32;          ///< complex with 32-bit floating point Real and Imagary numbers
     
    7074typedef bool psBool;                   ///< boolean value
    7175
     76/** Enumeration of data types for function elements.
     77 *  Contains replacements for native types.
     78 */
    7279typedef enum {
    7380    PS_TYPE_S8   = 0x0101,             ///< Character.
  • trunk/psLib/src/types/psPixels.h

    r4214 r4293  
    77 *  @author Robert DeSonia, MHPCC
    88 *
    9  *  @version $Revision: 1.5 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2005-06-11 02:19:05 $
     9 *  @version $Revision: 1.6 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2005-06-17 00:11:02 $
    1111 *
    1212 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    2121/// @{
    2222
     23/** Data structure for storing psPixel coordinates  */
    2324typedef struct
    2425{
    25     psS32 x;
    26     psS32 y;
     26    psS32 x;                           ///< x coordinate
     27    psS32 y;                           ///< y coordinate
    2728}
    2829psPixelCoord;
     
    3233 *  Usually an image mask is the best way to carry information about what
    3334 *  pixels mean what. However, in the case where the number of pixels in which
    34  *  we are interested is limited, it is more efficient to simply carry a list
     35 *  we are interested is limited, it is more efficient to simply carry a list
    3536 *  of pixels. An example of this is in the image combination code, where we
    3637 *  want to perform an operation on a relatively small fraction of pixels, and
    37  *  it is inefficient to go through an entire mask image checking each pixel.
     38 *  it is inefficient to go through an entire mask image checking each pixel.
    3839 *
    3940 */
    4041typedef struct
    4142{
    42     int n;
    43     int nalloc;
    44     psPixelCoord* data;
     43    int n;                             ///< Number in usa
     44    int nalloc;                        ///< Number allocated
     45    psPixelCoord* data;                ///< The pixel coordinates
    4546}
    4647psPixels;
     
    136137);
    137138
    138 /** Prints a psPixels to specified destination. */
     139/** Prints a psPixels to specified destination.
     140 * 
     141 *  @return bool:    True if successful.
     142*/
    139143bool p_psPixelsPrint(
    140     FILE *fd,
    141     psPixels* pixels,
    142     const char *name
     144    FILE *fd,                          ///< destination file descriptor
     145    psPixels* pixels,                  ///< psPixels to print
     146    const char *name                   ///< printf-style format of header line
    143147);
    144148
Note: See TracChangeset for help on using the changeset viewer.