Changeset 1478
- Timestamp:
- Aug 11, 2004, 10:17:35 AM (22 years ago)
- Location:
- trunk/psLib/src
- Files:
-
- 2 edited
-
collections/psVector.h (modified) (3 diffs)
-
mathtypes/psVector.h (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/collections/psVector.h
r1441 r1478 12 12 * @author Ross Harman, MHPCC 13 13 * 14 * @version $Revision: 1. 19$ $Name: not supported by cvs2svn $15 * @date $Date: 2004-08- 09 23:40:55 $14 * @version $Revision: 1.20 $ $Name: not supported by cvs2svn $ 15 * @date $Date: 2004-08-11 20:17:35 $ 16 16 * 17 17 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 63 63 /** Allocate a vector. 64 64 * 65 * Uses psLib memory allocation functions to create a vector collection of data as defined by the psType type. 65 * Uses psLib memory allocation functions to create a vector collection of 66 * data as defined by the psType type. 66 67 * 67 * @return psVector* : Pointer to psVector. 68 * 68 * @return psVector* Pointer to psVector. 69 69 */ 70 psVector* psVectorAlloc(unsigned int nalloc, ///< Total number of elements to make available. 71 psElemType dataType ///< Type of data to be held by vector. 72 ); 70 psVector* psVectorAlloc( 71 unsigned int nalloc, ///< Total number of elements to make available. 72 psElemType dataType ///< Type of data to be held by vector. 73 ); 73 74 74 75 /** Reallocate a vector. 75 76 * 76 * Uses psLib memory allocation functions to reallocate a vector collection of data. The vector is reallocated 77 * according to the psType type member contained within the vector. 77 * Uses psLib memory allocation functions to reallocate a vector collection 78 * of data. The vector is reallocated according to the psType type member 79 * contained within the vector. 78 80 * 79 * @return psVector* :Pointer to psVector.81 * @return psVector* Pointer to psVector. 80 82 * 81 83 */ 82 psVector* psVectorRealloc(unsigned int nalloc, ///< Total number of elements to make available. 83 psVector* restrict psVec ///< Vector to reallocate. 84 ); 84 psVector* psVectorRealloc( 85 unsigned int nalloc, ///< Total number of elements to make available. 86 psVector* restrict psVec ///< Vector to reallocate. 87 ); 85 88 86 89 /** Recycle a vector. 87 90 * 88 * Uses psLib memory allocation functions to reallocate a vector collection of data. The vector is reallocated 89 * according to the psElemType type parameter. 91 * Uses psLib memory allocation functions to reallocate a vector collection 92 * of data. The vector is reallocated according to the psElemType type 93 * parameter. 90 94 * 91 * @return psVector* :Pointer to psVector.95 * @return psVector* Pointer to psVector. 92 96 * 93 97 */ 94 psVector* psVectorRecycle(psVector* restrict psVec, 95 ///< Vector to recycle. If NULL, a new vector is created. No effort taken to 96 // preserve the values. 97 unsigned int nalloc, ///< Total number of elements to make available. 98 psElemType type ///< the datatype of the returned vector 99 ); 98 psVector* psVectorRecycle( 99 psVector* restrict psVec, 100 ///< Vector to recycle. If NULL, a new vector is created. No effort 101 ///< taken to preserve the values. 102 103 unsigned int nalloc, ///< Total number of elements to make available. 104 psElemType type ///< the datatype of the returned vector 105 ); 100 106 101 107 /** Sort an array of floats. … … 104 110 * all non-complex data types. 105 111 * 106 * @return ps FloatArray* : Pointer to sorted psFloatArray.112 * @return psVector* Pointer to sorted psVector. 107 113 */ 114 psVector* psVectorSort( 115 psVector* restrict outVector, ///< the output vector to recycle, or NULL if new vector desired. 116 const psVector* restrict inVector ///< the vector to sort. 117 ); 108 118 109 psVector* psVectorSort(psVector* restrict outVector, ///< the output vector to recycle, or NULL if new 110 // vector desired. 111 const psVector* restrict inVector ///< the vector to sort. 112 ); 113 114 /** Creates an array of indices based on sort odred of float array. 119 /** Creates an array of indices based on sort ordered of array. 115 120 * 116 * Sorts a n array of floatsand creates an integer array holding indices of121 * Sorts a vector and creates an integer array holding indices of 117 122 * sorted float values based on pre-sort index positions. 118 123 * 119 * @return ps IntArray* : Pointer to psIntArray of sorted indices.124 * @return psVector* vector of the indices of sort. 120 125 */ 121 122 psVector* psVectorSortIndex(psVector* restrict outVector, const psVector* restrict inVector); 126 psVector* psVectorSortIndex( 127 psVector* restrict outVector, ///< vector to recycle 128 const psVector* restrict inVector ///< vector to sort 129 ); 123 130 124 131 /// @} -
trunk/psLib/src/mathtypes/psVector.h
r1441 r1478 12 12 * @author Ross Harman, MHPCC 13 13 * 14 * @version $Revision: 1. 19$ $Name: not supported by cvs2svn $15 * @date $Date: 2004-08- 09 23:40:55 $14 * @version $Revision: 1.20 $ $Name: not supported by cvs2svn $ 15 * @date $Date: 2004-08-11 20:17:35 $ 16 16 * 17 17 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 63 63 /** Allocate a vector. 64 64 * 65 * Uses psLib memory allocation functions to create a vector collection of data as defined by the psType type. 65 * Uses psLib memory allocation functions to create a vector collection of 66 * data as defined by the psType type. 66 67 * 67 * @return psVector* : Pointer to psVector. 68 * 68 * @return psVector* Pointer to psVector. 69 69 */ 70 psVector* psVectorAlloc(unsigned int nalloc, ///< Total number of elements to make available. 71 psElemType dataType ///< Type of data to be held by vector. 72 ); 70 psVector* psVectorAlloc( 71 unsigned int nalloc, ///< Total number of elements to make available. 72 psElemType dataType ///< Type of data to be held by vector. 73 ); 73 74 74 75 /** Reallocate a vector. 75 76 * 76 * Uses psLib memory allocation functions to reallocate a vector collection of data. The vector is reallocated 77 * according to the psType type member contained within the vector. 77 * Uses psLib memory allocation functions to reallocate a vector collection 78 * of data. The vector is reallocated according to the psType type member 79 * contained within the vector. 78 80 * 79 * @return psVector* :Pointer to psVector.81 * @return psVector* Pointer to psVector. 80 82 * 81 83 */ 82 psVector* psVectorRealloc(unsigned int nalloc, ///< Total number of elements to make available. 83 psVector* restrict psVec ///< Vector to reallocate. 84 ); 84 psVector* psVectorRealloc( 85 unsigned int nalloc, ///< Total number of elements to make available. 86 psVector* restrict psVec ///< Vector to reallocate. 87 ); 85 88 86 89 /** Recycle a vector. 87 90 * 88 * Uses psLib memory allocation functions to reallocate a vector collection of data. The vector is reallocated 89 * according to the psElemType type parameter. 91 * Uses psLib memory allocation functions to reallocate a vector collection 92 * of data. The vector is reallocated according to the psElemType type 93 * parameter. 90 94 * 91 * @return psVector* :Pointer to psVector.95 * @return psVector* Pointer to psVector. 92 96 * 93 97 */ 94 psVector* psVectorRecycle(psVector* restrict psVec, 95 ///< Vector to recycle. If NULL, a new vector is created. No effort taken to 96 // preserve the values. 97 unsigned int nalloc, ///< Total number of elements to make available. 98 psElemType type ///< the datatype of the returned vector 99 ); 98 psVector* psVectorRecycle( 99 psVector* restrict psVec, 100 ///< Vector to recycle. If NULL, a new vector is created. No effort 101 ///< taken to preserve the values. 102 103 unsigned int nalloc, ///< Total number of elements to make available. 104 psElemType type ///< the datatype of the returned vector 105 ); 100 106 101 107 /** Sort an array of floats. … … 104 110 * all non-complex data types. 105 111 * 106 * @return ps FloatArray* : Pointer to sorted psFloatArray.112 * @return psVector* Pointer to sorted psVector. 107 113 */ 114 psVector* psVectorSort( 115 psVector* restrict outVector, ///< the output vector to recycle, or NULL if new vector desired. 116 const psVector* restrict inVector ///< the vector to sort. 117 ); 108 118 109 psVector* psVectorSort(psVector* restrict outVector, ///< the output vector to recycle, or NULL if new 110 // vector desired. 111 const psVector* restrict inVector ///< the vector to sort. 112 ); 113 114 /** Creates an array of indices based on sort odred of float array. 119 /** Creates an array of indices based on sort ordered of array. 115 120 * 116 * Sorts a n array of floatsand creates an integer array holding indices of121 * Sorts a vector and creates an integer array holding indices of 117 122 * sorted float values based on pre-sort index positions. 118 123 * 119 * @return ps IntArray* : Pointer to psIntArray of sorted indices.124 * @return psVector* vector of the indices of sort. 120 125 */ 121 122 psVector* psVectorSortIndex(psVector* restrict outVector, const psVector* restrict inVector); 126 psVector* psVectorSortIndex( 127 psVector* restrict outVector, ///< vector to recycle 128 const psVector* restrict inVector ///< vector to sort 129 ); 123 130 124 131 /// @}
Note:
See TracChangeset
for help on using the changeset viewer.
