Changeset 198
- Timestamp:
- Mar 9, 2004, 5:54:55 PM (22 years ago)
- Location:
- trunk/archive/pslib/include
- Files:
-
- 6 edited
-
psAstrom.h (modified) (7 diffs)
-
psColour.h (modified) (1 diff)
-
psImages.h (modified) (12 diffs)
-
psObjects.h (modified) (9 diffs)
-
psPosition.h (modified) (5 diffs)
-
psStdArrays.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/archive/pslib/include/psAstrom.h
r160 r198 10 10 /* Include colour definitions */ 11 11 #include "psColour.h" 12 #include "psMatrix.h" 12 13 13 14 … … 21 22 int xyColourOrder; //!< Spatial (x,y) order of polynomial in colour times x and y 22 23 int xyMagOrder; //!< Spatial (x,y) order of polynomial in magnitude times x and y 23 enumpsColourRef colourRef; //!< Colour reference24 psColourRef colourRef; //!< Colour reference 24 25 psDoubleArray *restrict coeff; //!< Coefficients of astrometric solution 25 26 psDoubleArray *restrict coeffErr; //!< Error in coefficients … … 28 29 /** Constructor */ 29 30 psAstromCoeffs * 30 psAstromCoeffsAlloc(int xyOrder, //!< Spatial (x,y) order of polynomial31 int colourOrder, //!< Order of polynomial in colour32 int magOrder,//!< Order of polynomial in magnitude33 int xyColourOrder, //!< Spatial (x,y) order of polynomial in colour times x and y34 int xyMagOrder, //!< Spatial (x,y) order of polynomial in magnitude times x and y35 enumpsColourRef colourRef //!< Colour reference31 psAstromCoeffsAlloc(int xyOrder, //!< Spatial (x,y) order of polynomial 32 int colourOrder, //!< Order of polynomial in colour 33 int magOrder, //!< Order of polynomial in magnitude 34 int xyColourOrder, //!< Spatial (x,y) order of polynomial in colour times x and y 35 int xyMagOrder, //!< Spatial (x,y) order of polynomial in magnitude times x and y 36 psColourRef colourRef //!< Colour reference 36 37 ); 37 38 … … 112 113 float rotation; //!< Rotation of OTA on the focal plane. Specified from +x through +y 113 114 psCellDescriptionArray *restrict cells; //!< Cell descriptions 114 psOTAAstrom *astrom;//!< OTA astrometry115 struct psOTAAstrom *astrom; //!< OTA astrometry 115 116 } psOTADescription; 116 117 … … 157 158 158 159 /** Constructor */ 159 ps Astrom *160 ps AstromAlloc(const psTelPointing *telescope //!< Telescope pointing, used to initialise the tp data.161 ); 162 163 /** Destructor */ 164 void 165 ps AstromFree(psAstrom *restrict myAstrom //!< Object to destroy160 psOTAAstrom * 161 psOTAAstromAlloc(const psTelPointing *telescope //!< Telescope pointing, used to initialise the tp data. 162 ); 163 164 /** Destructor */ 165 void 166 psOTAAstromFree(psOTAAstrom *restrict myAstrom //!< Object to destroy 166 167 ); 167 168 … … 204 205 float 205 206 psGetParallactic(const psSkyPos *restrict position, //!< Position on the sky 206 realsiderealTime //!< Sidereal time207 float siderealTime //!< Sidereal time 207 208 ); 208 209 … … 210 211 float 211 212 psGetRefraction(float colour, //!< Colour of object 212 enum psColourRef colourRef;//!< Colour reference213 psColourRef colourRef, //!< Colour reference 213 214 psTelPointing telescope //!< Telescope pointing information, for airmass, temp and pressure 214 215 ); -
trunk/archive/pslib/include/psColour.h
r153 r198 7 7 * 0.69 mag, y = 0.69 mag, w = 0.80 mag 8 8 */ 9 enum {9 typedef enum { 10 10 PS_COLOUR_NO_INFO, //!< No colour information 11 11 PS_COLOUR_G_MINUS_R, //!< Reference is g-r = 0.5 mag -
trunk/archive/pslib/include/psImages.h
r189 r198 1 1 # ifndef PS_IMAGES_H 2 2 # define PS_IMAGES_H 3 4 #include "psStdArrays.h" 5 #include "psUtils.h" 6 #include "psObjects.h" 7 #include "psMetaData.h" 8 #include "psStats.h" 3 9 4 10 /** General image manipulation functions. … … 15 21 16 22 PS_DECLARE_ARRAY_TYPE(psFloatArray); ///< Declare an array of real vectors (psFloatArrayArray). 17 PS_CREATE_ARRAY_TYPE(psFloatArray); ///< Create the data type (psFloatArrayArray).18 23 19 24 typedef unsigned char psU8; ///< BITPIX 8 (unsigned short) … … 34 39 psF32 **rows_f32; ///< pointers to psF32 data 35 40 psF64 **rows_f64; ///< pointers to psF64 data 36 psImage *parent;///< parent, if a subimage37 psImage *children;///< children of this region41 struct psImage *parent; ///< parent, if a subimage 42 struct psImage *children; ///< children of this region 38 43 int Nchildren; ///< number of subimages 39 psDlist md;///< metadata associated with image40 psObject Tableobjtable; ///< objects associated with image44 struct psMetaDataSet *md; ///< metadata associated with image 45 psObjectArray *objtable; ///< objects associated with image 41 46 } psImage; 42 47 … … 75 80 76 81 /*** various image pixel extractions ***/ 82 83 typedef enum { PS_STAT_MODE_MEDIAN } psStatMode; 84 77 85 /// Extract pixels from rectlinear region to a vector. 78 86 psFloatArray * … … 82 90 int nx, ///< width of region in x 83 91 int ny, ///< width of region in y 84 enum direction,///< direction of vector along slice85 enum statmode///< statistic applied to pixel group to find output value92 int direction, ///< direction of vector along slice 93 psStatMode statmode ///< statistic applied to pixel group to find output value 86 94 ); 87 95 … … 94 102 float ye, ///< ending y coord of cut 95 103 float dw, ///< width of cut 96 enumstatmode ///< statistic applied to pixel group to find output value97 );104 psStatMode statmode ///< statistic applied to pixel group to find output value 105 ); 98 106 99 107 /// Extract radial annulii data to a vector. … … 104 112 float radius, ///< outer radius of annulii 105 113 float dr, ///< radial step size of annulii 106 enum statmode///< statistic applied to pixel group to find output value107 );114 psStatMode statmode ///< statistic applied to pixel group to find output value 115 ); 108 116 109 117 /// Extract a 2-d contour from an image at the given threshold. … … 114 122 ); 115 123 116 /// Extract a 2-d contour from an image at the given threshold.117 psSpanArray *118 psImageContour (psImage *input, ///< create contour for this image119 float threshold ///< image at this threshold120 );121 122 124 /*** various image geometry manipulation ***/ 123 125 /// Rebin image to new scale. … … 125 127 psImageRebin (psImage *input, ///< rebin this image 126 128 float scale, ///< rebinning scale: doutput = scale*dinput 127 enum statmode///< statistic used in performing interpolation / summing129 psStatMode statmode ///< statistic used in performing interpolation / summing 128 130 ); 129 131 … … 155 157 /// How to represent the output values? 156 158 void 157 psImageGetStats (psImage *input, enumstatmode);159 psImageGetStats (psImage *input, psStatMode statmode); 158 160 159 161 /// Construct a histogram from an image (or subimage). 160 162 psHistogram * 161 psImageHistogram (psHistogram ,///< input histogram description & target162 psImage *input ,///< determine histogram of this image163 );163 psImageHistogram (psHistogram *hist, ///< input histogram description & target 164 psImage *input ///< determine histogram of this image 165 ); 164 166 165 167 /// Fit a 2-D polynomial surface to an image. 166 168 psFloatArrayArray * 167 169 psImageFitPolynomial (psImage *input, ///< image to fit 168 int xorder ///< order of polynomial in x-dir170 int xorder, ///< order of polynomial in x-dir 169 171 int yorder ///< order of polynomial in y-dir 170 172 ); … … 207 209 /// Write an image section to named file (which may exist). 208 210 psImage * 209 psImageFWriteSection (psImage *input, ///< image to write out210 int x, ///< starting x coord of region211 int y, ///< starting y coord of region212 int z, ///< plane of interest213 char *extname, ///< MEF extension name214 FILE *f ///< file descriptor to write data to211 psImageFWriteSection(psImage *input, ///< image to write out 212 int x, ///< starting x coord of region 213 int y, ///< starting y coord of region 214 int z, ///< plane of interest 215 char *extname, ///< MEF extension name 216 FILE *f ///< file descriptor to write data to 215 217 ); 216 218 217 219 /// Read only header from image file. 218 psMetadata *219 psImageReadHeader (psMetadata *output, ///< read data to this structure220 char *extname, ///< MEF extension name ("PHU" for primary header)221 char *filename ///< file to read from220 struct psMetadata * 221 psImageReadHeader(struct psMetadata *output, ///< read data to this structure 222 char *extname, ///< MEF extension name ("PHU" for primary header) 223 char *filename ///< file to read from 222 224 ); 223 225 224 226 /// Read only header from image file descriptor. 225 psMetadata *226 psImageFReadHeader ( psMetadata *output,///< read data to this structure227 struct psMetadata * 228 psImageFReadHeader (struct psMetadata *output, ///< read data to this structure 227 229 char *extname, ///< MEF extension name ("PHU" for primary header) 228 230 FILE *f ///< file descriptor to read from … … 233 235 psImage * 234 236 psImageFFT (psImage *input, ///< image to FFT 235 enumdirection ///< FFT direction237 int direction ///< FFT direction 236 238 ); 237 239 -
trunk/archive/pslib/include/psObjects.h
r160 r198 17 17 #include "psImages.h" 18 18 19 20 19 /***********************************************************************************************************/ 21 20 … … 31 30 float sky, skyErr; //!< Local sky level, and associated error 32 31 float colour, colourErr; //!< Colour and associated error, if known 33 enumpsColourRef colourRef; //!< Colour reference32 psColourRef colourRef; //!< Colour reference 34 33 psBitMask *quality; //!< Bit mask for quality information 35 34 } psObject; … … 53 52 /** Associates objects on an image with the image */ 54 53 typedef struct { 55 const psImage *image;//!< Image that produced the objects, which has metadata we need54 const struct psImage *image; //!< Image that produced the objects, which has metadata we need 56 55 psObjectArray *objects; //!< The objects 57 56 } psImageObjects; … … 59 58 /** Constructor */ 60 59 psImageObjects * 61 psImageObjectsAlloc(const psImage *image, //!< Image that produced the objects, which has metadata we need62 psObjectArray *objects //!< The objects63 );60 psImageObjectsAlloc(const struct psImage *image, //!< Image that produced the objects, with needed metadata 61 psObjectArray *objects //!< The objects 62 ); 64 63 65 64 /** Destructor */ … … 72 71 /** Objects from a catalogue */ 73 72 typedef struct { 74 enumpsCatalogue catalogue; //!< Source catalogue from which objects come73 psCatalogue catalogue; //!< Source catalogue from which objects come 75 74 psObjectArray *object; //!< The objects 76 75 } psCatalogueObjects; … … 79 78 psCatalogueObjects * 80 79 psCatalogueObjectsAlloc(enum psCatalogue *catalogue, //!< Source catalogue 81 psObjectArray *objects //!< The objects82 );80 psObjectArray *objects //!< The objects 81 ); 83 82 84 83 /** Destructor */ 85 84 void 86 psCatalogueObjectsFree(psCatalog eObjects *restrict myCatalogueObjects //!< Object to destroy85 psCatalogueObjectsFree(psCatalogueObjects *restrict myCatalogueObjects //!< Object to destroy 87 86 ); 88 87 … … 91 90 /** A "super" object --- an object with multiple detections in different images */ 92 91 typedef struct { 93 const psImageArray *images;//!< Images that provided the different measurements92 const struct psImageArray *images; //!< Images that provided the different measurements 94 93 const psObjectArray *objects; //!< Individual object measurements 95 94 … … 103 102 /** Constructor */ 104 103 psSuperObject * 105 psSuperObjectAlloc(const psImageArray *images, //!< The images with the measurements106 const psObjectArray *objects //!< Object measurements107 );104 psSuperObjectAlloc(const struct psImageArray *images, //!< The images with the measurements 105 const psObjectArray *objects //!< Object measurements 106 ); 108 107 109 108 /** Destructor */ … … 167 166 float magLower, //!< Lower bound for colour 168 167 float magUpper, //!< Upper bound for colour 169 enum psColourRef colourRef//!< Only select those with this colour reference168 psColourRef colourRef //!< Only select those with this colour reference 170 169 ); 171 170 -
trunk/archive/pslib/include/psPosition.h
r183 r198 4 4 /* Include array declaration macros */ 5 5 #include "psArray.h" 6 #include "psObjects.h" 6 7 7 8 /***********************************************************************************************************/ … … 16 17 17 18 /** Planets */ 18 enum {19 typedef enum { 19 20 PS_MERCURY = 1, 20 21 PS_VENUS = 2, … … 28 29 29 30 /** Catalogues */ 30 enum {31 typedef enum { 31 32 PS_PANSTARRS, //!< Pan-STARRS object catalogue 32 33 PS_USNO, //!< USNO-B1 catalogue … … 148 149 /** Get Planet positions */ 149 150 psSkyPos * 150 psGetPlanetPos( enumpsPlanetNum myPlanetNum, //!< Number for planet151 psGetPlanetPos(psPlanetNum myPlanetNum, //!< Number for planet 151 152 float mjd //!< MJD to get position for 152 153 ); 153 154 154 155 /** Get star list from catalogue */ 155 psObjectArray *156 struct psObjectArray * 156 157 psReadStarCatalogue(double ra, //!< RA of centre of search 157 158 double dec, //!< Declination of centre of search 158 159 float radius, //!< Radius of search for stars in catalogue 159 160 float mjd, //!< The epoch (in MJD) for which to get positions 160 enumpsCatalogue myCatalogue //!< The catalogue to use161 psCatalogue myCatalogue //!< The catalogue to use 161 162 ); 162 163 … … 186 187 187 188 /***********************************************************************************************************/ 189 #endif -
trunk/archive/pslib/include/psStdArrays.h
r153 r198 2 2 #define PS_TYPES_H 3 3 4 #include <complex.h> 4 5 #include "psArray.h" 5 6
Note:
See TracChangeset
for help on using the changeset viewer.
