Changeset 344 for trunk/archive/pslib/include/psObject.h
- Timestamp:
- Mar 31, 2004, 5:01:04 PM (22 years ago)
- File:
-
- 1 edited
-
trunk/archive/pslib/include/psObject.h (modified) (8 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/archive/pslib/include/psObject.h
r251 r344 11 11 /** Object definition, to handle both objects we detect, and catalogues */ 12 12 typedef struct { 13 psCoord *cell; // !< Centre position on Cell, with associated error14 psCoord *sky; // !< Position on the sky, with associated error15 float mag, magErr; // !< Magnitude and associated error16 float isoMag, isoMagErr; // !< Isophotal magnitude and associated error17 float fwhm, fwhmErr; // !< FWHM and associated error18 float ellipA, ellipB; // !< Elliptical semi-major (A) and semi-minor (B) axes19 float ellipAngle; // !< Ellipse position angle20 float sky, skyErr; // !< Local sky level, and associated error21 float colour, colourErr; // !< Colour and associated error, if known22 psPhotSysrem colorPlus, colorMinus; // !< Colour reference23 psBitMask *quality; // !< Bit mask for quality information13 psCoord *cell; ///< Centre position on Cell, with associated error 14 psCoord *sky; ///< Position on the sky, with associated error 15 float mag, magErr; ///< Magnitude and associated error 16 float isoMag, isoMagErr; ///< Isophotal magnitude and associated error 17 float fwhm, fwhmErr; ///< FWHM and associated error 18 float ellipA, ellipB; ///< Elliptical semi-major (A) and semi-minor (B) axes 19 float ellipAngle; ///< Ellipse position angle 20 float sky, skyErr; ///< Local sky level, and associated error 21 float colour, colourErr; ///< Colour and associated error, if known 22 psPhotSysrem colorPlus, colorMinus; ///< Colour reference 23 psBitMask *quality; ///< Bit mask for quality information 24 24 psCell *parentCell; ///< Cell this measurement came from 25 25 } psObject; … … 37 37 /** An assembly of objects */ 38 38 typedef struct { 39 psType type; // !< Type of data. THIS STRUCT ELEMENT MUST BE FIRST IN THE STRUCT!40 int size; // !< Total number of elements available41 int n; // !< Number of elements in use42 psObject *arr; // !< The array data39 psType type; ///< Type of data. THIS STRUCT ELEMENT MUST BE FIRST IN THE STRUCT! 40 int size; ///< Total number of elements available 41 int n; ///< Number of elements in use 42 psObject *arr; ///< The array data 43 43 } psObjectArray; 44 44 45 45 /** Constructor */ 46 psObjectArray *psObjectArrayAlloc(int s, // !< Total number of elements to make available47 int n // !< Number of elements that will be used46 psObjectArray *psObjectArrayAlloc(int s, ///< Total number of elements to make available 47 int n ///< Number of elements that will be used 48 48 ); 49 49 /** Reallocator */ 50 psObjectArray *psObjectArrayRealloc(psObjectArray *myArray, // !< Array to reallocate51 int s // !< Total number of elements to make available50 psObjectArray *psObjectArrayRealloc(psObjectArray *myArray, ///< Array to reallocate 51 int s ///< Total number of elements to make available 52 52 ); 53 53 /** Destructor */ 54 void psObjectArrayFree(psObjectArray *restrict myArray // !< Array to free54 void psObjectArrayFree(psObjectArray *restrict myArray ///< Array to free 55 55 ); 56 56 … … 59 59 /** Associates objects on an image with the image */ 60 60 typedef struct { 61 const struct psImage *image; // !< Image that produced the objects, which has metadata we need62 psObjectArray *objects; // !< The objects61 const struct psImage *image; ///< Image that produced the objects, which has metadata we need 62 psObjectArray *objects; ///< The objects 63 63 } psImageObjects; 64 64 65 65 /** Constructor */ 66 66 psImageObjects * 67 psImageObjectsAlloc(const struct psImage *image, // !< Image that produced the objects, with needed metadata68 psObjectArray *objects // !< The objects67 psImageObjectsAlloc(const struct psImage *image, ///< Image that produced the objects, with needed metadata 68 psObjectArray *objects ///< The objects 69 69 ); 70 70 71 71 /** Destructor */ 72 72 void 73 psImageObjectsFree(psImageObjects *restrict myImageObjects // !< Object to destroy73 psImageObjectsFree(psImageObjects *restrict myImageObjects ///< Object to destroy 74 74 ); 75 75 … … 78 78 /** Objects from a catalogue */ 79 79 typedef struct { 80 psCatalogue catalogue; // !< Source catalogue from which objects come81 psObjectArray *object; // !< The objects80 psCatalogue catalogue; ///< Source catalogue from which objects come 81 psObjectArray *object; ///< The objects 82 82 } psCatalogueObjects; 83 83 84 84 /** Constructor */ 85 85 psCatalogueObjects * 86 psCatalogueObjectsAlloc(enum psCatalogue *catalogue, // !< Source catalogue87 psObjectArray *objects // !< The objects86 psCatalogueObjectsAlloc(enum psCatalogue *catalogue, ///< Source catalogue 87 psObjectArray *objects ///< The objects 88 88 ); 89 89 90 90 /** Destructor */ 91 91 void 92 psCatalogueObjectsFree(psCatalogueObjects *restrict myCatalogueObjects // !< Object to destroy92 psCatalogueObjectsFree(psCatalogueObjects *restrict myCatalogueObjects ///< Object to destroy 93 93 ); 94 94 … … 97 97 /** A "super" object --- an object with multiple detections in different images */ 98 98 typedef struct { 99 const struct psImageArray *images; // !< Images that provided the different measurements100 const psObjectArray *objects; // !< Individual object measurements99 const struct psImageArray *images; ///< Images that provided the different measurements 100 const psObjectArray *objects; ///< Individual object measurements 101 101 102 102 /* Derived quantities */ 103 psSkyPos *meanSkyPos; // !< Mean position on the sky104 double pmRA, pmDec; // !< Proper motion in RA and Dec105 double pmRAErr, pmDecErr; // !< Errors in proper motion106 float posChi2; // !< chi^2 for position103 psSkyPos *meanSkyPos; ///< Mean position on the sky 104 double pmRA, pmDec; ///< Proper motion in RA and Dec 105 double pmRAErr, pmDecErr; ///< Errors in proper motion 106 float posChi2; ///< chi^2 for position 107 107 } psSuperObject; 108 108 109 109 /** Constructor */ 110 110 psSuperObject * 111 psSuperObjectAlloc(const struct psImageArray *images, // !< The images with the measurements112 const psObjectArray *objects // !< Object measurements111 psSuperObjectAlloc(const struct psImageArray *images, ///< The images with the measurements 112 const psObjectArray *objects ///< Object measurements 113 113 ); 114 114 115 115 /** Destructor */ 116 116 void 117 psSuperObjectFree(psSuperObject *restrict mySuperObject // !< Object to destroy117 psSuperObjectFree(psSuperObject *restrict mySuperObject ///< Object to destroy 118 118 ); 119 119 … … 129 129 */ 130 130 psIntArray * 131 psCorrelateObjects(const psObjectArray *restrict myObjects1, // !< First bunch of objects132 const psObjectArray *restrict myObjects2, // !< Second bunch of objects133 const psOTADescription *myOTA1, // !< OTA description for first bunch of objects, or NULL for134 // !< sky135 const psOTADescription *myOTA2 // !< OTA description for second bunch of objects, or NULL for136 // !< sky131 psCorrelateObjects(const psObjectArray *restrict myObjects1, ///< First bunch of objects 132 const psObjectArray *restrict myObjects2, ///< Second bunch of objects 133 const psOTADescription *myOTA1, ///< OTA description for first bunch of objects, or NULL for 134 ///< sky 135 const psOTADescription *myOTA2 ///< OTA description for second bunch of objects, or NULL for 136 ///< sky 137 137 ); 138 138 … … 142 142 */ 143 143 int 144 psGetCorrelatedMatches(const psIntArray matches, // !< Index array specifying matches */145 const psObjectArray *restrict myObjects1, // !< First bunch of objects146 const psObjectArray *restrict myObjects2, // !< Second bunch of objects147 psObjectArray *matched1, // !< Matched objects in first bunch148 psObjectArray *matched2 // !< Matched objects in second bunch144 psGetCorrelatedMatches(const psIntArray matches, ///< Index array specifying matches */ 145 const psObjectArray *restrict myObjects1, ///< First bunch of objects 146 const psObjectArray *restrict myObjects2, ///< Second bunch of objects 147 psObjectArray *matched1, ///< Matched objects in first bunch 148 psObjectArray *matched2 ///< Matched objects in second bunch 149 149 ); 150 150 … … 155 155 /** Get objects within a particular magnitude range */ 156 156 psObjectArray * 157 psSelectObjectMag(psObjectArray *restrict myArray, // !< Bunch of objects to select from158 float magLower, // !< Lower bound for magnitude159 float magUpper // !< Upper bound for magnitude157 psSelectObjectMag(psObjectArray *restrict myArray, ///< Bunch of objects to select from 158 float magLower, ///< Lower bound for magnitude 159 float magUpper ///< Upper bound for magnitude 160 160 ); 161 161 162 162 /** Get objects within a radius on the sky */ 163 163 psObjectArray * 164 psSelectObjectSkyDist(psObjectArray *restrict myArray, // !< Bunch of objects to select from165 psSkyPos *skyPos, // !< Position on the sky166 float radius, // !< Radius of search167 int circleOrSquare // !< Circle = 1, Square = 2164 psSelectObjectSkyDist(psObjectArray *restrict myArray, ///< Bunch of objects to select from 165 psSkyPos *skyPos, ///< Position on the sky 166 float radius, ///< Radius of search 167 int circleOrSquare ///< Circle = 1, Square = 2 168 168 ); 169 169 170 170 /** Get objects within a particular colour range */ 171 171 psObjectArray * 172 psSelectObjectColour(psObjectArray *restrict myArray, // !< Bunch of objects to select from173 float magLower, // !< Lower bound for colour174 float magUpper, // !< Upper bound for colour175 psColourRef colourRef // !< Only select those with this colour reference172 psSelectObjectColour(psObjectArray *restrict myArray, ///< Bunch of objects to select from 173 float magLower, ///< Lower bound for colour 174 float magUpper, ///< Upper bound for colour 175 psColourRef colourRef ///< Only select those with this colour reference 176 176 ); 177 177
Note:
See TracChangeset
for help on using the changeset viewer.
