IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
May 11, 2004, 2:40:23 PM (22 years ago)
Author:
gusciora
Message:

I removed psImage.o temporarily (since it was not compiling).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/dataManip/psStats.h

    r563 r642  
    66 *  \ingroup MathGroup
    77 */
     8
     9/******************************************************************************
     10    The following typedefs and functions belong in the psArray.h and psArray.c
     11    files.  However, those files are not available at this time, due to the
     12    changing definition of the psLib data/functions.  For temporary purposes
     13    only, I am including them here so that I can continue coding while our
     14    basic data types are still being implemented.
     15 *****************************************************************************/
     16typedef enum {
     17    PS_TYPE_CHAR,
     18    PS_TYPE_SHORT,
     19    PS_TYPE_INT,
     20    PS_TYPE_LONG,
     21    PS_TYPE_UCHAR,
     22    PS_TYPE_USHORT,
     23    PS_TYPE_UINT,
     24    PS_TYPE_ULONG,
     25    PS_TYPE_FLOAT,
     26    PS_TYPE_DOUBLE,
     27    PS_TYPE_COMPLEX,
     28    PS_TYPE_OTHER,
     29} psElemType;
     30
     31typedef enum {
     32    PS_DIMEN_SCALAR,
     33    PS_DIMEN_VECTOR,
     34    PS_DIMEN_TRANSV,
     35    PS_DIMEN_IMAGE,
     36    PS_DIMEN_OTHER
     37} psDimen;
     38
     39typedef struct
     40{
     41    psElemType type;
     42    psDimen dimen;
     43}
     44psType;
     45
     46typedef struct
     47{
     48    psType type;                ///< Type of data.
     49    int nalloc;                 ///< Total number of elements available.
     50    int n;                      ///< Number of elements in use.
     51
     52    union {
     53        int *vecI;
     54        float *vecF;
     55        double *vecD;
     56        //        complex float *vecC;
     57        void **vecP;
     58    }vec;                       ///< Union with array data.
     59}
     60psVector;
     61
     62psVector *psVectorAlloc(int        nalloc,
     63                        psElemType type)
     64{
     65    return(NULL);
     66}
     67
     68psVector *psVectorRealloc(psVector myVector,
     69                          int nalloc)
     70{
     71    return(NULL);
     72}
     73
     74void psVectorFree(psVector *restrict psArr)
     75{}
    876
    977/** statistics which may be calculated */
     
    65133/** Do Statistics on an array.  Returns a status value. \ingroup MathGroup */
    66134psStats *
    67 psArrayStats(const psFloatArray *restrict myArray, ///< Array to be analysed
    68              const psIntArray *restrict maskArray, ///< Ignore elements where (maskArray & maskVal) != 0
    69              ///< May be NULL
    70              unsigned int maskVal, ///< Only mask elements with one of these bits set in maskArray
     135psArrayStats(const psVector *restrict myVector, ///< Vector to be analysed
     136             // must be FLOAT
     137             const psVector *restrict maskVector, ///< Ignore elements where (maskVector & maskVal) != 0
     138             // must be INT or NULL
     139             unsigned int maskVal, ///< Only mask elements with one of these bits set in maskVector
    71140             psStats *stats  ///< stats structure defines stats to be calculated and how
    72141            );
     
    87156typedef struct
    88157{
    89     const psFloatArray *restrict lower; ///< Lower bounds for the bins
    90     const psFloatArray *restrict upper; ///< Upper bounds for the bins
    91     psIntArray *nums;   ///< Number in each of the bins
    92     float minVal, maxVal;  ///< Minimum and maximum values
    93     int minNum, maxNum;   ///< Number below the minimum and above the maximum
     158    const psVector *restrict lower; ///< Lower bounds for the bins (FLOAT)
     159    const psVector *restrict upper; ///< Upper bounds for the bins (FLOAT)
     160    psVector *nums;   ///< Number in each of the bins (INT)
     161    float minVal;
     162    float maxVal;  ///< Minimum and maximum values
     163    int minNum;
     164    int maxNum;   ///< Number below the minimum and above the maximum
    94165}
    95166psHistogram;
     
    104175/** Generic constructor \ingroup MathGroup */
    105176psHistogram *
    106 psHistogramAllocGeneric(const psFloatArray *restrict lower, ///< Lower bounds for the bins
    107                         const psFloatArray *restrict upper, ///< Upper bounds for the bins
     177psHistogramAllocGeneric(const psVector *restrict lower, ///< Lower bounds for the bins
     178                        const psVector *restrict upper, ///< Upper bounds for the bins
    108179                        float minVal, ///< Minimum value
    109180                        float maxVal ///< Maximum value
     
    119190psHistogram *
    120191psGetArrayHistogram(psHistogram *restrict myHist, ///< Histogram data
    121                     const psFloatArray *restrict myArray ///< Array to analyse
     192                    const psVector *restrict myVector ///< Vector to analyse
    122193                   );
    123194
Note: See TracChangeset for help on using the changeset viewer.