Changeset 21323
- Timestamp:
- Feb 5, 2009, 10:44:04 AM (17 years ago)
- Location:
- trunk/pswarp/src
- Files:
-
- 21 edited
-
pswarp.c (modified) (1 diff)
-
pswarp.h (modified) (5 diffs)
-
pswarpArguments.c (modified) (8 diffs)
-
pswarpCleanup.c (modified) (1 diff)
-
pswarpDefine.c (modified) (6 diffs)
-
pswarpDefineSkycell.c (modified) (1 diff)
-
pswarpErrorCodes.c.in (modified) (3 diffs)
-
pswarpErrorCodes.h.in (modified) (1 diff)
-
pswarpHeadersLoad.c (modified) (1 diff)
-
pswarpLoop.c (modified) (13 diffs)
-
pswarpMapGrid.c (modified) (11 diffs)
-
pswarpMatchRange.c (modified) (2 diffs)
-
pswarpParseCamera.c (modified) (2 diffs)
-
pswarpPixelFraction.c (modified) (5 diffs)
-
pswarpSetMaskBits.c (modified) (1 diff)
-
pswarpSetThreads.c (modified) (1 diff)
-
pswarpThreads.c (modified) (2 diffs)
-
pswarpTransformReadout.c (modified) (5 diffs)
-
pswarpTransformSources.c (modified) (4 diffs)
-
pswarpTransformTile.c (modified) (6 diffs)
-
pswarpVersion.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/pswarp/src/pswarp.c
r20410 r21323 1 /** @file pswarp.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.14 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 -
trunk/pswarp/src/pswarp.h
r20307 r21323 1 /** @file pswarp.h 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.17 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 #ifdef HAVE_CONFIG_H 2 14 #include <config.h> … … 14 26 15 27 #include "pswarpErrorCodes.h" 16 #define PSWARP_RECIPE "PSWARP" // Name of the recipe to use17 #define PSASTRO_RECIPE "PSASTRO" // Name of the recipe to use28 #define PSWARP_RECIPE "PSWARP" ///< Name of the recipe to use 29 #define PSASTRO_RECIPE "PSASTRO" ///< Name of the recipe to use 18 30 19 #define PSWARP_ANALYSIS_VARFACTOR "PSWARP.VARFACTOR" // Name for variance factor in analysis metadata20 #define PSWARP_ANALYSIS_GOODPIX "PSWARP.GOODPIX" // Name for number of good pixels in analysis metadata31 #define PSWARP_ANALYSIS_VARFACTOR "PSWARP.VARFACTOR" ///< Name for variance factor in analysis metadata 32 #define PSWARP_ANALYSIS_GOODPIX "PSWARP.GOODPIX" ///< Name for number of good pixels in analysis metadata 21 33 22 // a single pswarpMap converts coordinates from one image to a second image 23 // the linear model is only valid over a limited range of pixels 34 /** 35 * a single pswarpMap converts coordinates from one image to a second image 36 * the linear model is only valid over a limited range of pixels 37 */ 24 38 typedef struct { 25 39 double Xo, Xx, Xy; … … 29 43 } pswarpMap; 30 44 31 // the pswarpMapGrid carries a collection of pswarpMag structures representing the 32 // local value of the pswarpMap at different locations in the image. 45 /* the pswarpMapGrid carries a collection of pswarpMag structures representing 46 * the local value of the pswarpMap at different locations in the image. 47 */ 33 48 typedef struct { 34 49 pswarpMap ***maps; 35 int nXpts, nYpts; // number of x,y samples in the grid36 int nXpix, nYpix; // x,y spacing in src image pixels of grid samples37 double xMin, yMin; // coordinate of first grid sample50 int nXpts, nYpts; ///< number of x,y samples in the grid 51 int nXpix, nYpix; ///< x,y spacing in src image pixels of grid samples 52 double xMin, yMin; ///< coordinate of first grid sample 38 53 } pswarpMapGrid; 39 54 40 55 typedef struct { 41 / / values which are common to all tiles56 /** values which are common to all tilesa */ 42 57 pmReadout *input; 43 58 pmReadout *output; … … 46 61 psImage *region; 47 62 48 / / input values for this tile63 /** input values for this tile */ 49 64 int gridX; 50 65 int gridY; 51 66 52 / / output values for this tile53 long goodPixels; // Number of good pixels54 int xMin, xMax, yMin, yMax; // Bounds of tile67 /** output values for this tile */ 68 long goodPixels; //< Number of good pixels 69 int xMin, xMax, yMin, yMax; //< Bounds of tile 55 70 } pswarpTransformTileArgs; 56 71 … … 91 106 ); 92 107 93 // define threads for this program 108 /** 109 * define threads for this program 110 */ 94 111 bool pswarpSetThreads (); -
trunk/pswarp/src/pswarpArguments.c
r20347 r21323 1 /** @file pswarpArguments.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.23 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 # include <glob.h> … … 26 38 27 39 { 28 int arg; // Argument Number40 int arg; ///< Argument Number 29 41 if ((arg = psArgumentGet(argc, argv, "-psphot-visual"))) { 30 42 psArgumentRemove(arg, &argc, argv); … … 105 117 } 106 118 107 // Parse the recipe and format into the arguments 119 /** 120 * Parse the recipe and format into the arguments 121 */ 108 122 bool pswarpOptions(pmConfig *config) 109 123 { … … 116 130 117 131 // Get grid size 118 bool status; // Status of MD lookup132 bool status; ///< Status of MD lookup 119 133 int nGridX = psMetadataLookupS32(&status, recipe, "GRID.NX"); 120 134 if (!status || nGridX <= 0) { … … 129 143 130 144 // Get interpolation mode 131 const char *name = psMetadataLookupStr (&status, recipe, "INTERPOLATION.MODE"); // Name of interp mode145 const char *name = psMetadataLookupStr (&status, recipe, "INTERPOLATION.MODE"); ///< Name of interp mode 132 146 if (!name) { 133 147 name = "BILINEAR"; 134 148 psLogMsg("pswarp", 3, "defaulting to %s interpolation", name); 135 149 } 136 psImageInterpolateMode interpolationMode = psImageInterpolateModeFromString(name); // Mode for interp.150 psImageInterpolateMode interpolationMode = psImageInterpolateModeFromString(name); ///< Mode for interp. 137 151 if (interpolationMode == PS_INTERPOLATE_NONE) { 138 152 interpolationMode = PS_INTERPOLATE_BILINEAR; … … 148 162 } 149 163 150 float poorFrac = psMetadataLookupF32(&status, recipe, "POOR.FRAC"); // Frac of bad flux for a "poor"164 float poorFrac = psMetadataLookupF32(&status, recipe, "POOR.FRAC"); ///< Frac of bad flux for a "poor" 151 165 if (!status) { 152 166 poorFrac = 0.0; … … 154 168 } 155 169 156 float acceptFrac = psMetadataLookupF32(&status, recipe, "ACCEPT.FRAC"); // Min fraction of good pixels170 float acceptFrac = psMetadataLookupF32(&status, recipe, "ACCEPT.FRAC"); ///< Min fraction of good pixels 157 171 if (!status) { 158 172 acceptFrac = 0.0; … … 194 208 if (dump_file) { 195 209 const char *skyCamera = psMetadataLookupStr(NULL, config->arguments, 196 "SKYCELL.CAMERA"); // Name of camera for skycell210 "SKYCELL.CAMERA"); ///< Name of camera for skycell 197 211 pmConfigCamerasCull(config, skyCamera); 198 212 pmConfigRecipesCull(config, "PSWARP,PPSTATS,PSPHOT,MASKS"); -
trunk/pswarp/src/pswarpCleanup.c
r18839 r21323 1 /** @file pswarpCleanup.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.8 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 -
trunk/pswarp/src/pswarpDefine.c
r18712 r21323 1 /** @file pswarpDefine.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.15 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 // this function loads the skycell metadata3 14 15 /** 16 * loads the skycell metadata 17 */ 4 18 bool pswarpDefine (pmConfig *config) { 5 19 … … 42 56 view->cell = 0; 43 57 view->readout = 0; 44 pmCell *source = pmFPAfileThisCell(config->files, view, "PSWARP.SKYCELL"); // Source cell45 pmHDU *hdu = pmHDUFromCell(source); // HDU for source58 pmCell *source = pmFPAfileThisCell(config->files, view, "PSWARP.SKYCELL"); ///< Source cell 59 pmHDU *hdu = pmHDUFromCell(source); ///< HDU for source 46 60 if (!hdu || !hdu->header) { 47 61 psError(PS_ERR_UNEXPECTED_NULL, false, "Unable to find header for sky cell."); … … 49 63 return false; 50 64 } 51 int numCols = psMetadataLookupS32(NULL, hdu->header, "NAXIS1"); // Number of columns52 int numRows = psMetadataLookupS32(NULL, hdu->header, "NAXIS2"); // Number of rows65 int numCols = psMetadataLookupS32(NULL, hdu->header, "NAXIS1"); ///< Number of columns 66 int numRows = psMetadataLookupS32(NULL, hdu->header, "NAXIS2"); ///< Number of rows 53 67 54 pmCell *target = pmFPAviewThisCell(view, output->fpa); // Target cell55 pmReadout *readout = pmReadoutAlloc(target); // Target readout68 pmCell *target = pmFPAviewThisCell(view, output->fpa); ///< Target cell 69 pmReadout *readout = pmReadoutAlloc(target); ///< Target readout 56 70 readout->image = psImageAlloc(numCols, numRows, PS_TYPE_F32); 57 71 psImageInit(readout->image, NAN); … … 72 86 view->cell = 0; 73 87 view->readout = -1; 74 pmHDU *phu = pmFPAviewThisPHU(view, skycell->fpa); // Skycell PHU75 pmHDU *hdu = pmFPAviewThisHDU(view, skycell->fpa); // Skycell header88 pmHDU *phu = pmFPAviewThisPHU(view, skycell->fpa); ///< Skycell PHU 89 pmHDU *hdu = pmFPAviewThisHDU(view, skycell->fpa); ///< Skycell header 76 90 bool bilevelAstrometry = false; 77 91 if (phu) { … … 83 97 84 98 // We read from the skycell into the output. i.e., the output receives the desired astrometry. 85 pmChip *outputChip = pmFPAviewThisChip(view, output->fpa); // Chip in the output99 pmChip *outputChip = pmFPAviewThisChip(view, output->fpa); ///< Chip in the output 86 100 if (bilevelAstrometry) { 87 101 if (!pmAstromReadBilevelMosaic(output->fpa, phu->header)) { … … 104 118 } 105 119 106 const char *name = psMetadataLookupStr(NULL, input->fpa->concepts, "FPA.OBS"); // Name of FPA120 const char *name = psMetadataLookupStr(NULL, input->fpa->concepts, "FPA.OBS"); ///< Name of FPA 107 121 view->chip = view->cell = view->readout = -1; 108 122 pmFPAAddSourceFromView(output->fpa, name, view, output->format); -
trunk/pswarp/src/pswarpDefineSkycell.c
r21168 r21323 1 /** @file pswarpDefineSkycell.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.12 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 3 // XXX this function is based on pmFPAfileDefineFromArgs 4 // a skycell consists of only one file 15 /** 16 * \brief XXX this function is based on pmFPAfileDefineFromArgs 17 * a skycell consists of only one file 5 18 6 // search for argname on the config->argument list 7 // construct an FPA based on the files in this list (must represent a single FPA) 8 // built the association between the FPA elements (CHIP/CELL) and the files 9 // define the pmFPAfile filename and bind it to this FPA 10 // save the pmFPAfile on config->files 11 // return the pmFPAfile (a view to the one saved on config->files) 19 * search for argname on the config->argument list and construct 20 * an FPA based on the files in this list (must represent a single FPA) 21 * built the association between the FPA elements (CHIP/CELL) and the files 22 * define the pmFPAfile filename and bind it to this FPA 23 * save the pmFPAfile on config->files 24 * @return the pmFPAfile (a view to the one saved on config->files) 25 */ 12 26 bool pswarpDefineSkycell (pmFPAfile **outFile, pmConfig **outConfig, pmConfig *config, const char *filename, const char *argname) 13 27 { -
trunk/pswarp/src/pswarpErrorCodes.c.in
r11282 r21323 1 /** @file pswarpErrorCodes.c.in 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.3 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 13 #include "pslib.h" 14 #include "pswarpErrorCodes.h" 15 1 16 /* 2 17 * The line … … 5 20 * will be replaced by values from errorCodes.dat 6 21 */ 7 #include "pslib.h"8 #include "pswarpErrorCodes.h"9 10 22 void pswarpErrorRegister(void) 11 23 { … … 14 26 { PSWARP_ERR_${ErrorCode}, "${ErrorDescription}"}, 15 27 }; 16 static int nerror = PSWARP_ERR_NERROR - PSWARP_ERR_BASE; // number of values in enum28 static int nerror = PSWARP_ERR_NERROR - PSWARP_ERR_BASE; ///< number of values in enum 17 29 18 30 for (int i = 0; i < nerror; i++) { -
trunk/pswarp/src/pswarpErrorCodes.h.in
r10946 r21323 1 /** @file pswarpErrorCodes.h.in 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.2 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 #if !defined(PSWARP_ERROR_CODES_H) 2 14 #define PSWARP_ERROR_CODES_H -
trunk/pswarp/src/pswarpHeadersLoad.c
r13109 r21323 1 /** @file pswarpHeadersLoad.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.3 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 3 // XXX this function should load all of the PSWARP.INPUT headers 4 // it should examine the overlap between each chip in PSWARP.INPUT 5 // and the output (pswarpMatchRange) and select/de-select the chips 6 // and/or cell which contribute pixels. 7 8 // pswarpDataLoad should then load the pixel of the needed chips 9 10 // all of the different astrometry analysis modes use the same data load loop 15 /** XXX this function should load all of the PSWARP.INPUT headers 16 * it should examine the overlap between each chip in PSWARP.INPUT 17 * and the output (pswarpMatchRange) and select/de-select the chips 18 * and/or cell which contribute pixels. 19 * 20 * pswarpDataLoad should then load the pixel of the needed chips 21 * 22 * all of the different astrometry analysis modes use the same data load loop 23 */ 11 24 bool pswarpHeadersLoad (pmConfig *config) { 12 25 -
trunk/pswarp/src/pswarpLoop.c
r21256 r21323 1 /** @file pswarpLoop.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.36 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 #include "pswarp.h" 2 14 #include <ppStats.h> 3 15 4 #define WCS_NONLIN_TOL 0.001 // Non-linear tolerance for header WCS 5 #define PSPHOT_FIND_PSF 1 // Use psphot's findPSF function? 6 #define TESTING 0 // Testing output? 7 8 // Lists of file rules used at different stages 9 #include "pswarpFileNames.h" 10 11 // XXX these are generic functions which should be moved to psModules 12 // Activate a list of files 13 static void fileActivation(pmConfig *config, // Configuration 14 char **files, // Files to turn on/off 15 bool state // Activation state 16 #define WCS_NONLIN_TOL 0.001 ///< Non-linear tolerance for header WCS 17 #define PSPHOT_FIND_PSF 1 ///< Use psphot's findPSF function? 18 #define TESTING 0 ///< Testing output? 19 20 #include "pswarpFileNames.h" ///< Lists of file rules used at different stages 21 22 /** 23 * XXX these are generic functions which should be moved to psModules 24 * Activate a list of files 25 */ 26 static void fileActivation(pmConfig *config, ///< Configuration 27 char **files, ///< Files to turn on/off 28 bool state ///< Activation state 16 29 ) 17 30 { … … 22 35 } 23 36 24 // Run down the FPA hierarchy, checking files 25 static bool ioChecksBefore(pmConfig *config // Configuration 37 /** 38 * Run down the FPA hierarchy, checking files 39 */ 40 static bool ioChecksBefore(pmConfig *config ///< Configuration 26 41 ) 27 42 { 28 pmFPAview *view = pmFPAviewAlloc(0); // View for checking29 bool status = true; // Status of checks43 pmFPAview *view = pmFPAviewAlloc(0); ///< View for checking 44 bool status = true; ///< Status of checks 30 45 status &= pmFPAfileIOChecks(config, view, PM_FPA_BEFORE); 31 46 view->chip = 0; … … 37 52 } 38 53 39 // Run up the FPA hierarchy, checking files 40 static bool ioChecksAfter(pmConfig *config // Configuration 54 /** 55 * Run up the FPA hierarchy, checking files 56 */ 57 static bool ioChecksAfter(pmConfig *config ///< Configuration 41 58 ) 42 59 { 43 pmFPAview *view = pmFPAviewAlloc(0); // View for checking60 pmFPAview *view = pmFPAviewAlloc(0); ///< View for checking 44 61 view->chip = view->cell = 0; 45 bool status = true; // Status of checks62 bool status = true; ///< Status of checks 46 63 status &= pmFPAfileIOChecks(config, view, PM_FPA_AFTER); 47 64 view->cell = -1; … … 54 71 55 72 56 // Loop over the inputs, warp them to the output skycell and then write out the output. 73 /** 74 * Loop over the inputs, warp them to the output skycell and then write out the output. 75 */ 57 76 bool pswarpLoop(pmConfig *config) 58 77 { … … 100 119 psFree (view); 101 120 102 bool mdok; // Status of MD lookup103 const char *statsName = psMetadataLookupStr(&mdok, config->arguments, "STATS"); // Filename for statistics104 psMetadata *stats = NULL; // Container for statistics105 FILE *statsFile = NULL; // File stream for statistics121 bool mdok; ///< Status of MD lookup 122 const char *statsName = psMetadataLookupStr(&mdok, config->arguments, "STATS"); ///< Filename for statistics 123 psMetadata *stats = NULL; ///< Container for statistics 124 FILE *statsFile = NULL; ///< File stream for statistics 106 125 if (mdok && statsName && strlen(statsName) > 0) { 107 126 psString resolved = pmConfigConvertFilename(statsName, config, true, true); … … 245 264 } 246 265 247 pmCell *outCell = output->parent; // Output cell248 pmChip *outChip = outCell->parent; // Output chip249 pmFPA *outFPA = outChip->parent; // Output FP266 pmCell *outCell = output->parent; ///< Output cell 267 pmChip *outChip = outCell->parent; ///< Output chip 268 pmFPA *outFPA = outChip->parent; ///< Output FP 250 269 251 270 if (!pswarpPixelFraction(output, stats, config)) { … … 265 284 varFactor /= goodPix; 266 285 267 psMetadataItem *vfItem = psMetadataLookup(outCell->concepts, "CELL.VARFACTOR"); // Item to update286 psMetadataItem *vfItem = psMetadataLookup(outCell->concepts, "CELL.VARFACTOR"); ///< Item to update 268 287 psAssert(vfItem && vfItem->type == PS_TYPE_F32, "Concept should be as specified."); 269 288 if (!isfinite(vfItem->data.F32)) { … … 283 302 psFree(cells); 284 303 285 psRegion *trimsec = psMetadataLookupPtr(NULL, outCell->concepts, "CELL.TRIMSEC"); // Trim section286 trimsec->x0 = trimsec->x1 = trimsec->y0 = trimsec->y1 = 0; // All pixels304 psRegion *trimsec = psMetadataLookupPtr(NULL, outCell->concepts, "CELL.TRIMSEC"); ///< Trim section 305 trimsec->x0 = trimsec->x1 = trimsec->y0 = trimsec->y1 = 0; ///< All pixels 287 306 288 307 if (!psMetadataCopy(outFPA->concepts, input->fpa->concepts)) { … … 293 312 } 294 313 295 pmHDU *hdu = outFPA->hdu; // HDU for the output warped image314 pmHDU *hdu = outFPA->hdu; ///< HDU for the output warped image 296 315 297 316 // Copy header from target 298 317 { 299 pmFPAview *skyView = pmFPAviewAlloc(0); // View into skycell318 pmFPAview *skyView = pmFPAviewAlloc(0); ///< View into skycell 300 319 skyView->chip = skyView->cell = 0; 301 320 pmCell *cell = pmFPAfileThisCell(config->files, skyView, "PSWARP.SKYCELL"); // Skycell cell 302 321 psFree(skyView); 303 pmHDU *skyHDU = pmHDUFromCell(cell); // HDU322 pmHDU *skyHDU = pmHDUFromCell(cell); ///< HDU 304 323 if (!skyHDU) { 305 324 psError(PS_ERR_UNEXPECTED_NULL, false, "Unable to find skycell HDU."); … … 333 352 pmFPACopy(photFile->fpa, outFPA); 334 353 335 pmFPAview *view = pmFPAviewAlloc(0); // View into skycell354 pmFPAview *view = pmFPAviewAlloc(0); ///< View into skycell 336 355 view->chip = view->cell = view->readout = 0; 337 356 … … 340 359 // We can adjust the weight directly since this is a deep copy 341 360 pmReadout *photRO = pmFPAviewThisReadout(view, photFile->fpa); 342 float vf = psMetadataLookupF32(NULL, photRO->parent->concepts, "CELL.VARFACTOR"); // Variance factor361 float vf = psMetadataLookupF32(NULL, photRO->parent->concepts, "CELL.VARFACTOR"); ///< Variance factor 343 362 psBinaryOp(photRO->weight, photRO->weight, "*", psScalarAlloc(vf, PS_TYPE_F32)); 344 363 … … 359 378 #if (TESTING) 360 379 { 361 #define PSF_SIZE 20 // Half-size of PSF362 #define PSF_FLUX 10000 // Central flux for PSF380 #define PSF_SIZE 20 ///< Half-size of PSF 381 #define PSF_FLUX 10000 ///< Central flux for PSF 363 382 pmChip *photChip = pmFPAviewThisChip(view, photFile->fpa); 364 383 pmPSF *psf = psMetadataLookupPtr(NULL, photChip->analysis, "PSPHOT.PSF"); … … 390 409 const char *chipName = psMetadataLookupStr(NULL, output->parent->parent->concepts, "CHIP.NAME"); 391 410 const char *cellName = psMetadataLookupStr(NULL, output->parent->concepts, "CELL.NAME"); 392 psString headerName = NULL; // Header name for MD5411 psString headerName = NULL; ///< Header name for MD5 393 412 psStringAppend(&headerName, "MD5_%s_%s_%d", chipName, cellName, view->readout); 394 psVector *md5 = psImageMD5(output->image); // md5 hash395 psString md5string = psMD5toString(md5); // String413 psVector *md5 = psImageMD5(output->image); ///< md5 hash 414 psString md5string = psMD5toString(md5); ///< String 396 415 psFree(md5); 397 416 psMetadataAddStr(hdu->header, PS_LIST_TAIL, headerName, PS_META_REPLACE, -
trunk/pswarp/src/pswarpMapGrid.c
r18839 r21323 1 /** @file pswarpMapGrid.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.7 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 3 // pswarpMapGridFromImage builds a set (a grid) of locally-linear maps which convert the source 4 // coordinates (src) to destination coordinates (dest). we construct a grid with superpixel 5 // spacing of nXpix, nYpix. The transformation for each grid cell is valid for the superpixel. 6 // The grid over-fills the source image so every source image pixel is guaranteed to have a map. 15 /** 16 * pswarpMapGridFromImage builds a set (a grid) of locally-linear maps which convert the source 17 * coordinates (src) to destination coordinates (dest). we construct a grid with superpixel 18 * spacing of nXpix, nYpix. The transformation for each grid cell is valid for the superpixel. 19 * The grid over-fills the source image so every source image pixel is guaranteed to have a map. 20 */ 7 21 pswarpMapGrid *pswarpMapGridFromImage (pmReadout *dest, pmReadout *src, int nXpix, int nYpix) { 8 22 … … 41 55 } 42 56 43 // set the grid coordinate (gridX,gridY) for the given source image coordinate (ix,iy) 44 // XXX return true if the result is on the src image, false otherwise (???) 57 /** 58 * set the grid coordinate (gridX,gridY) for the given source image coordinate (ix,iy) 59 * XXX return true if the result is on the src image, false otherwise (???) 60 */ 45 61 bool pswarpMapGridSetGrid (pswarpMapGrid *grid, int ix, int iy, int *gridX, int *gridY) { 46 62 … … 51 67 } 52 68 53 // given the specified grid coordinate (gridX, gridY), return the min and max coordinates for the tile 69 /** 70 * given the specified grid coordinate (gridX, gridY), return the min and max coordinates for the tile 71 */ 54 72 bool pswarpMapGridCoordRange (pswarpMapGrid *grid, int gridX, int gridY, psPlane *min, psPlane *max) { 55 73 … … 63 81 } 64 82 65 // given the specified grid coordinate (gridX), return the x-coordinate for the source image 66 // corresponding to the next grid cell 83 /** 84 * given the specified grid coordinate (gridX), return the x-coordinate for the source image 85 * corresponding to the next grid cell 86 */ 67 87 int pswarpMapGridNextGrid_X (pswarpMapGrid *grid, int gridX) { 68 88 … … 71 91 } 72 92 73 // given the specified grid coordinate (gridY), return the y-coordinate for the source image 74 // corresponding to the next grid cell 93 /** 94 * given the specified grid coordinate (gridY), return the y-coordinate for the source image 95 * corresponding to the next grid cell 96 */ 75 97 int pswarpMapGridNextGrid_Y (pswarpMapGrid *grid, int gridY) { 76 98 … … 79 101 } 80 102 81 // measure the max error accumulated in applying one grid point to its neighbors 82 // XXX double-check this 103 /** 104 * measure the max error accumulated in applying one grid point to its neighbors 105 * XXX double-check this 106 */ 83 107 double pswarpMapGridMaxError (pswarpMapGrid *grid) { 84 108 … … 102 126 } 103 127 104 // given the source coordinate (inX,inY), return the destination coordinate (outX,outY) 128 /** 129 * given the source coordinate (inX,inY), return the destination coordinate (outX,outY) 130 */ 105 131 bool pswarpMapApply (double *outX, double *outY, pswarpMap *map, double inX, double inY) { 106 132 … … 111 137 } 112 138 113 // determine the (linear) map for the given pixel (ix,iy) from source image (src) to the destination image (dest) 114 // pixel is in src coords. input and output pixel coordinates are in the parent frame of the image (Note that the 115 // astrometric transformations are supplied for the parent image coordinate frame. 139 /** 140 * determine the (linear) map for the given pixel (ix,iy) from source image (src) to the destination image (dest) 141 * pixel is in src coords. input and output pixel coordinates are in the parent frame of the image (Note that the 142 * astrometric transformations are supplied for the parent image coordinate frame. 143 */ 116 144 bool pswarpMapSetLocalModel (pswarpMap *map, pmReadout *dest, pmReadout *src, int ix, int iy) { 117 145 … … 139 167 // XXX need to include readout->cell->chip offsets 140 168 141 / / V(0,0) position169 /** V(0,0) position */ 142 170 offset->x = ix; 143 171 offset->y = iy; … … 149 177 psPlaneTransformApply (V00, chipDest->fromFPA, FP); 150 178 151 / / V(1,0) position179 /** V(1,0) position */ 152 180 offset->x = ix + 1; 153 181 offset->y = iy; … … 159 187 psPlaneTransformApply (V10, chipDest->fromFPA, FP); 160 188 161 / / V(0,1) position189 /** V(0,1) position */ 162 190 offset->x = ix; 163 191 offset->y = iy + 1; -
trunk/pswarp/src/pswarpMatchRange.c
r12526 r21323 1 /** @file pswarpMatchRange.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.5 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 … … 13 25 *maxY = PS_MAX (*maxY, srcPix->y); 14 26 15 // we are warping from src to dest. find the max overlapping pixels in the INPUT (src) 16 // coordinate frame. NOTE: these are in the parent pixel frame since the astrometric 17 // transformation refers to the parent frame 27 /** we are warping from src to dest. find the max overlapping pixels in the INPUT (src) 28 * coordinate frame. NOTE: these are in the parent pixel frame since the astrometric 29 * transformation refers to the parent frame 30 */ 18 31 bool pswarpMatchRange (int *minX, int *minY, int *maxX, int *maxY, pmReadout *dest, pmReadout *src) { 19 32 -
trunk/pswarp/src/pswarpParseCamera.c
r20331 r21323 1 /** @file pswarpParseCamera.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.23 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 … … 4 16 { 5 17 bool status; 6 bool mdok; // Status of MD lookup18 bool mdok; ///< Status of MD lookup 7 19 pmFPAfile *skycell = NULL; 8 20 pmConfig *skyConfig = NULL; -
trunk/pswarp/src/pswarpPixelFraction.c
r21183 r21323 1 /** @file pswarpPixelFraction.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.6 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 #ifdef HAVE_CONFIG_H 2 14 #include <config.h> … … 30 42 bool status; 31 43 32 float minFrac = psMetadataLookupF32(NULL, config->arguments, "ACCEPT.FRAC"); // Minimum fraction44 float minFrac = psMetadataLookupF32(NULL, config->arguments, "ACCEPT.FRAC"); ///< Minimum fraction 33 45 34 46 // load the recipe … … 43 55 psAssert (status, "MASK.OUTPUT was not defined"); 44 56 45 psImage *image = readout->image; // Image of interest46 psImage *mask = readout->mask; // Mask image57 psImage *image = readout->image; ///< Image of interest 58 psImage *mask = readout->mask; ///< Mask image 47 59 48 int numCols = image->numCols, numRows = image->numRows; // Size of image60 int numCols = image->numCols, numRows = image->numRows; ///< Size of image 49 61 long numPix = numCols * numRows; 50 62 … … 52 64 int xMin = INT_MAX, xMax = -INT_MAX, yMin = INT_MAX, yMax = -INT_MAX; 53 65 54 long numBad = 0; // Number of bad pixels66 long numBad = 0; ///< Number of bad pixels 55 67 for (int y = 0; y < numRows; y++) { 56 68 for (int x = 0; x < numCols; x++) { … … 74 86 } 75 87 76 float goodFrac = (numPix - numBad) / (float)numPix; // Fraction of good pixels77 bool accept = (goodFrac >= minFrac ? true : false); // Accept this readout?88 float goodFrac = (numPix - numBad) / (float)numPix; ///< Fraction of good pixels 89 bool accept = (goodFrac >= minFrac ? true : false); ///< Accept this readout? 78 90 79 91 if (stats) { -
trunk/pswarp/src/pswarpSetMaskBits.c
r21183 r21323 1 /** @file pswarpSetMaskBits.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.4 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 3 / /This function is called by the stand-alone pswarp program to set the mask values in the4 //config file. It sets the named mask values MASK.PSPHOT and MARK.PSPHOT in the PSPHOT5 //recipe. Functions or programs which call psphotReadout as a library function must set these6 //named mask values in the PSPHOT recipe on their own. This function should only be called7 //after the first header of the input mask image has been loaded and the named mask bits8 //updated in the config metadata.9 15 /** This function is called by the stand-alone pswarp program to set the mask values in the 16 * config file. It sets the named mask values MASK.PSPHOT and MARK.PSPHOT in the PSPHOT 17 * recipe. Functions or programs which call psphotReadout as a library function must set these 18 * named mask values in the PSPHOT recipe on their own. This function should only be called 19 * after the first header of the input mask image has been loaded and the named mask bits 20 * updated in the config metadata. 21 */ 10 22 bool pswarpSetMaskBits (pmConfig *config) { 11 23 12 psImageMaskType maskIn = 0x00; // mask for the input image13 psImageMaskType markIn = 0x00; // mark for the input image14 psImageMaskType maskOut = 0x00; // mask for the output image24 psImageMaskType maskIn = 0x00; ///< mask for the input image 25 psImageMaskType markIn = 0x00; ///< mark for the input image 26 psImageMaskType maskOut = 0x00; ///< mask for the output image 15 27 16 28 // this function sets the required single-image mask bits -
trunk/pswarp/src/pswarpSetThreads.c
r19299 r21323 1 /** @file pswarpSetThreads.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.5 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 3 // each thread runs this function, starting a new job when it finished with an old one 4 // it is called with a (void *) pointer to its own thread pointer 15 /** each thread runs this function, starting a new job when it finished with an old one 16 * it is called with a (void *) pointer to its own thread pointer 17 */ 5 18 bool pswarpThread_pswarpTransformTile(psThreadJob *job) 6 19 { -
trunk/pswarp/src/pswarpThreads.c
r18839 r21323 1 /** @file pswarpThreads.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.3 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 # include "pswarp.h" 2 14 … … 39 51 } 40 52 41 // create a pool of Nthreads 53 /** 54 * create a pool of Nthreads 55 */ 42 56 bool pswarpThreadsCreate (int nThreads) { 43 57 -
trunk/pswarp/src/pswarpTransformReadout.c
r21183 r21323 1 /** @file pswarpTransformReadout.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.15 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 #include "pswarp.h" 2 14 3 // NOTE: in this function, the coordinates are transformed from the OUTPUT to the INPUT 15 /** 16 * NOTE: in this function, the coordinates are transformed from the OUTPUT to the INPUT 17 */ 4 18 bool pswarpTransformReadout(pmReadout *output, pmReadout *input, pmConfig *config) 5 19 { 6 20 // XXX this implementation currently ignores the use of the region 7 psImage *region = NULL; // Region to transform21 psImage *region = NULL; ///< Region to transform 8 22 9 23 psTimerStart("warp"); 10 24 11 25 // Get warp parameters 12 bool mdok; // Status of MD lookup13 int nGridX = psMetadataLookupS32(NULL, config->arguments, "GRID.NX"); // Number of grid points in x14 int nGridY = psMetadataLookupS32(NULL, config->arguments, "GRID.NY"); // Number of grid points in y26 bool mdok; ///< Status of MD lookup 27 int nGridX = psMetadataLookupS32(NULL, config->arguments, "GRID.NX"); ///< Number of grid points in x 28 int nGridY = psMetadataLookupS32(NULL, config->arguments, "GRID.NY"); ///< Number of grid points in y 15 29 psImageInterpolateMode interpolationMode = psMetadataLookupS32(NULL, config->arguments, 16 "INTERPOLATION.MODE"); // Mode for interp17 int numKernels = psMetadataLookupS32(NULL, config->arguments, "INTERPOLATION.NUM"); // Number of kernels30 "INTERPOLATION.MODE"); ///< Mode for interp 31 int numKernels = psMetadataLookupS32(NULL, config->arguments, "INTERPOLATION.NUM"); ///< Number of kernels 18 32 19 33 // load the recipe … … 27 41 psAssert(mdok, "MASK.INPUT was not defined"); 28 42 29 int nThreads = psMetadataLookupS32(&mdok, config->arguments, "NTHREADS"); // Number of threads43 int nThreads = psMetadataLookupS32(&mdok, config->arguments, "NTHREADS"); ///< Number of threads 30 44 if (!mdok) { 31 45 nThreads = 0; 32 46 } 33 float poorFrac = psMetadataLookupF32(NULL, config->arguments, "POOR.FRAC"); // Flux fraction for "poor"47 float poorFrac = psMetadataLookupF32(NULL, config->arguments, "POOR.FRAC"); ///< Flux fraction for "poor" 34 48 35 49 // pswarpMapGridFromImage builds a set of locally-linear maps which convert the … … 42 56 43 57 // Get range of interest 44 int xOutMin, xOutMax, yOutMin, yOutMax; // Output pixel range58 int xOutMin, xOutMax, yOutMin, yOutMax; ///< Output pixel range 45 59 pswarpMatchRange(&xOutMin, &yOutMin, &xOutMax, &yOutMax, input, output); 46 60 … … 53 67 } 54 68 55 int xGridMin = nGridX, xGridMax = 0, yGridMin = nGridY, yGridMax = 0; // Grid range56 int xGrid, yGrid; // Grid coordinates69 int xGridMin = nGridX, xGridMax = 0, yGridMin = nGridY, yGridMax = 0; ///< Grid range 70 int xGrid, yGrid; ///< Grid coordinates 57 71 pswarpMapGridSetGrid(grid, xOutMin, yOutMin, &xGrid, &yGrid); 58 72 CHECK_GRID_RANGE(); … … 121 135 psThreadJob *job = NULL; 122 136 int xMin = output->image->numCols, xMax = 0, yMin = output->image->numRows, yMax = 0; // Bounds 123 int goodPixels = 0; // total number of good pixels across all tiles137 int goodPixels = 0; ///< total number of good pixels across all tiles 124 138 while ((job = psThreadJobGetDone()) != NULL) { 125 139 if (job->args->n < 1) { -
trunk/pswarp/src/pswarpTransformSources.c
r20578 r21323 1 /** @file pswarpTransformSources.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.7 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 #include "pswarp.h" 2 14 3 #define SOURCE_ARRAY_BUFFER 100 // Size to grow the array of sources at a time15 #define SOURCE_ARRAY_BUFFER 100 ///< Size to grow the array of sources at a time 4 16 5 // NOTE: in this function, the coordinates are transformed from the OUTPUT to the INPUT 17 /** 18 * NOTE: in this function, the coordinates are transformed from the OUTPUT to the INPUT 19 */ 6 20 bool pswarpTransformSources(pmReadout *output, pmReadout *input, pmConfig *config) 7 21 { … … 33 47 // this does not cost us so much time. 34 48 for (int i = 0; i < inSources->n; i++) { 35 pmSource *source = inSources->data[i]; // Source of interest36 pmModel *model = source->modelPSF; // Model for this source37 float xIn, yIn; // Coordinates of source49 pmSource *source = inSources->data[i]; ///< Source of interest 50 pmModel *model = source->modelPSF; ///< Model for this source 51 float xIn, yIn; ///< Coordinates of source 38 52 xIn = model->params->data.F32[PM_PAR_XPOS] - input->image->col0; 39 53 yIn = model->params->data.F32[PM_PAR_YPOS] - input->image->row0; 40 54 41 int xGrid, yGrid; // Grid coordinates for local map55 int xGrid, yGrid; ///< Grid coordinates for local map 42 56 if (!pswarpMapGridSetGrid(sourceGrid, xIn + 0.5, yIn + 0.5, &xGrid, &yGrid)) { 43 57 psError(PS_ERR_UNKNOWN, false, "Unable to get grid coordinates for source at %f,%f\n", … … 53 67 } 54 68 55 pswarpMap *map = sourceGrid->maps[xGrid][yGrid]; // Locally linear transformation56 double xOut, yOut; // Output coordinates69 pswarpMap *map = sourceGrid->maps[xGrid][yGrid]; ///< Locally linear transformation 70 double xOut, yOut; ///< Output coordinates 57 71 if (!pswarpMapApply(&xOut, &yOut, map, xIn + 0.5, yIn + 0.5)) { 58 72 psError(PS_ERR_UNKNOWN, false, "Unable to transform coordinates for source at %f,%f\n", … … 73 87 // Magnitudes will be off if there's any change in scale, but for our purposes (mainly x,y and 74 88 // relative flux) that's OK. 75 pmSource *new = pmSourceAlloc(); // New source89 pmSource *new = pmSourceAlloc(); ///< New source 76 90 new->peak = pmPeakAlloc(xOut, yOut, source->peak->flux, PM_PEAK_LONE); 77 91 new->peak->flux = source->peak->flux; -
trunk/pswarp/src/pswarpTransformTile.c
r21183 r21323 1 /** @file pswarpTransformTile.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.8 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 #include "pswarp.h" 2 14 … … 36 48 bool pswarpTransformTile(pswarpTransformTileArgs *args) 37 49 { 38 psImage *inImage = args->input->image; // Input image39 psImage *outImage = args->output->image; // Output image50 psImage *inImage = args->input->image; ///< Input image 51 psImage *outImage = args->output->image; ///< Output image 40 52 41 int inNumCols = inImage->numCols, inNumRows = inImage->numRows; // Size of input image42 int outNumCols = outImage->numCols, outNumRows = outImage->numRows; // Size of output image43 int outCol0 = outImage->col0, outRow0 = outImage->row0; // Offset of output image53 int inNumCols = inImage->numCols, inNumRows = inImage->numRows; ///< Size of input image 54 int outNumCols = outImage->numCols, outNumRows = outImage->numRows; ///< Size of output image 55 int outCol0 = outImage->col0, outRow0 = outImage->row0; ///< Offset of output image 44 56 45 psPlane minPt, maxPt; // Minimum and maximum points for this tile57 psPlane minPt, maxPt; ///< Minimum and maximum points for this tile 46 58 pswarpMapGridCoordRange(args->grid, args->gridX, args->gridY, &minPt, &maxPt); 47 59 … … 52 64 psImageMaskType **inMaskData = (args->input->mask) ? args->input->mask->data.PS_TYPE_IMAGE_MASK_DATA : NULL; 53 65 54 pswarpMap *map = args->grid->maps[args->gridX][args->gridY]; // Map for this tile55 psImage *region = args->region; // Region to transform66 pswarpMap *map = args->grid->maps[args->gridX][args->gridY]; ///< Map for this tile 67 psImage *region = args->region; ///< Region to transform 56 68 57 / / Bounds for iteration69 /** Bounds for iteration */ 58 70 int xMin = PS_MAX(minPt.x, 0); 59 71 int xMax = PS_MIN(maxPt.x, outNumCols); … … 62 74 63 75 // Iterate over the output image pixels (parent frame) 64 long goodPixels = 0; // Number of input pixels landing on the output image76 long goodPixels = 0; ///< Number of input pixels landing on the output image 65 77 for (int y = yMin; y < yMax; y++) { 66 78 for (int x = xMin; x < xMax; x++) { … … 80 92 } 81 93 94 double imageValue, varValue; // Value of image and variance map 95 82 96 // psImagePixelInterpolate determines the value at pixel coordinate (x,y) in child coordinates 83 double imageValue, varValue; // Value of image and variance map84 97 psImageMaskType maskValue = inMaskData ? inMaskData[(int)yIn][(int)xIn] : 0; // Value of mask 98 85 99 if (!psImageInterpolate(&imageValue, &varValue, &maskValue, xIn, yIn, args->interp)) { 86 100 psError(PS_ERR_UNKNOWN, false, "Unable to interpolate image."); … … 88 102 } 89 103 90 int xOut = x - outCol0, yOut = y - outRow0; // Position on output image104 int xOut = x - outCol0, yOut = y - outRow0; ///< Position on output image 91 105 92 106 if (outImageData) { -
trunk/pswarp/src/pswarpVersion.c
r10946 r21323 1 /** @file pswarpVersion.c 2 * 3 * @brief 4 * 5 * @ingroup pswarp 6 * 7 * @author IfA 8 * @version $Revision: 1.2 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2009-02-05 20:44:04 $ 10 * Copyright 2009 Institute for Astronomy, University of Hawaii 11 */ 12 1 13 #ifdef HAVE_CONFIG_H 2 14 #include <config.h> … … 8 20 #include "pswarp.h" 9 21 10 static const char *cvsTag = "$Name: not supported by cvs2svn $";// CVS tag name22 static const char *cvsTag = "$Name: not supported by cvs2svn $";///< CVS tag name 11 23 12 24 psString pswarpVersion(void) 13 25 { 14 psString version = NULL; // Version, to return26 psString version = NULL; ///< Version, to return 15 27 psStringAppend(&version, "%s-%s",PACKAGE_NAME,PACKAGE_VERSION); 16 28 return version; … … 19 31 psString pswarpVersionLong(void) 20 32 { 21 psString version = pswarpVersion(); // Version, to return22 psString tag = psStringStripCVS(cvsTag, "Name"); // CVS tag33 psString version = pswarpVersion(); ///< Version, to return 34 psString tag = psStringStripCVS(cvsTag, "Name"); ///< CVS tag 23 35 psStringAppend(&version, " (cvs tag %s) %s, %s", tag, __DATE__, __TIME__); 24 36 psFree(tag);
Note:
See TracChangeset
for help on using the changeset viewer.
