IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 21239


Ignore:
Timestamp:
Jan 30, 2009, 12:00:45 PM (17 years ago)
Author:
giebink
Message:

Doxygen comments made consistent

Location:
branches/eam_branch_20081230/ppArith/src
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branch_20081230/ppArith/src/ppArith.c

    r21229 r21239  
    66 *
    77 *  @author IfA
    8  *  @version $Revision: 1.4.32.1 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2009-01-30 01:38:08 $
     8 *  @version $Revision: 1.4.32.2 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2009-01-30 22:00:45 $
    1010 *  Copyright 2009 Institute for Astronomy, University of Hawaii
    1111 */
     
    2323int main(int argc, char *argv[])
    2424{
    25     psExit exitValue = PS_EXIT_SUCCESS; /** Exit value */
     25    psExit exitValue = PS_EXIT_SUCCESS; ///< Exit value
    2626    psTimerStart("ppArith");
    2727    psLibInit(NULL);
    2828
    29     pmConfig *config = pmConfigRead(&argc, argv, PPARITH_RECIPE); /** Configuration */
     29    pmConfig *config = pmConfigRead(&argc, argv, PPARITH_RECIPE); ///< Configuration
    3030    if (!config) {
    3131        psErrorStackPrint(stderr, "Error reading configuration.");
  • branches/eam_branch_20081230/ppArith/src/ppArith.h

    r21229 r21239  
    66 *
    77 *  @author IfA
    8  *  @version $Revision: 1.3.32.1 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2009-01-30 01:37:55 $
     8 *  @version $Revision: 1.3.32.2 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2009-01-30 22:00:45 $
    1010 *  Copyright 2009 Institute for Astronomy, University of Hawaii
    1111 */
     
    1717/// @addtogroup ppArith
    1818/// @{
    19 #define PPARITH_RECIPE "PPARITH"            /** Name of the recipe to use */
     19#define PPARITH_RECIPE "PPARITH"            ///< Name of the recipe to use
    2020
    21 /// Parse the arguments
    22 bool ppArithArguments(int argc, char *argv[], /**< Command-line arguments */
    23                       pmConfig *config    /**< Configuration */
     21/**
     22 * Parse the arguments
     23 */
     24bool ppArithArguments(int argc, char *argv[], ///< Command-line arguments
     25                      pmConfig *config    ///< Configuration
    2426    );
    2527
    26 /// Parse the camera input
    27 bool ppArithCamera(pmConfig *config       /**< Configuration */
     28/**
     29 * Parse the camera input
     30 */
     31bool ppArithCamera(pmConfig *config       ///< Configuration
    2832    );
    2933
    30 /// Loop over the FPA hierarchy
    31 bool ppArithLoop(pmConfig *config         /**< Configuration */
     34/**
     35 * Loop over the FPA hierarchy
     36 */
     37bool ppArithLoop(pmConfig *config         ///< Configuration
    3238    );
    3339
    34 /// Perform arithmetic on the readout
    35 bool ppArithReadout(pmReadout *output,  /**< Output readout */
    36                     const pmReadout *input1, /**< Input readout */
    37                     const pmReadout *input2, /**< Input readout */
    38                     const pmConfig *config, /**< Configuration */
    39                     const pmFPAview *view /**< View of readout on which to operate */
     40/**
     41 * Perform arithmetic on the readout
     42 */
     43bool ppArithReadout(pmReadout *output,  ///< Output readout
     44                    const pmReadout *input1, ///< Input readout
     45                    const pmReadout *input2, ///< Input readout
     46                    const pmConfig *config, ///< Configuration
     47                    const pmFPAview *view ///< View of readout on which to operate
    4048    );
    4149
    42 /// Put the program version information into a metadata
    43 void ppArithVersionMetadata(psMetadata *metadata /**< Metadata to populate */
     50/**
     51 * Put the program version information into a metadata
     52 */
     53void ppArithVersionMetadata(psMetadata *metadata ///< Metadata to populate
    4454    );
    4555
  • branches/eam_branch_20081230/ppArith/src/ppArithArguments.c

    r21229 r21239  
    66 *
    77 *  @author IfA
    8  *  @version $Revision: 1.4.30.1 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2009-01-30 01:38:25 $
     8 *  @version $Revision: 1.4.30.2 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2009-01-30 22:00:45 $
    1010 *  Copyright 2009 Institute for Astronomy, University of Hawaii
    1111 */
     
    2222#include "ppArith.h"
    2323
    24 // Print usage information and die
    25 static void usage(const char *program,  // Name of the program
    26                   psMetadata *arguments, // Command-line arguments
    27                   pmConfig *config      // Configuration
     24/**
     25 * Print usage information and die
     26 */
     27static void usage(const char *program,  ///< Name of the program
     28                  psMetadata *arguments, ///< Command-line arguments
     29                  pmConfig *config      ///< Configuration
    2830    )
    2931{
     
    4042}
    4143
    42 // Get a string value from the command-line and add it to the target
    43 static bool valueArgStr(psMetadata *arguments, // Command-line arguments
    44                         const char *argName, // Argument name in the command-line arguments
    45                         const char *mdName, // Name for value in the metadata
    46                         psMetadata *target // Target metadata to which to add value
     44/**
     45 * Get a string value from the command-line and add it to the target
     46 */
     47static bool valueArgStr(psMetadata *arguments, ///< Command-line arguments
     48                        const char *argName, ///< Argument name in the command-line arguments
     49                        const char *mdName, ///< Name for value in the metadata
     50                        psMetadata *target ///< Target metadata to which to add value
    4751                        )
    4852{
    49     psString value = psMetadataLookupStr(NULL, arguments, argName); /** Value of interest */
     53    psString value = psMetadataLookupStr(NULL, arguments, argName); ///< Value of interest
    5054    if (value && strlen(value) > 0) {
    5155        return psMetadataAddStr(target, PS_LIST_TAIL, mdName, 0, NULL, value);
     
    5559
    5660/**
    57  * \fn fileList
    5861 * Add a single filename to the arguments as an array, so that it can be used with pmFPAfileBindFromArgs, etc
    5962 */
    60 static void fileList(const char *file, // The symbolic name for the file
    61                      const char *name, // The name of the file
    62                      const char *comment, // Description of the file
    63                      pmConfig *config // Configuration
     63static void fileList(const char *file, ///< The symbolic name for the file
     64                     const char *name, ///< The name of the file
     65                     const char *comment, ///< Description of the file
     66                     pmConfig *config ///< Configuration
    6467    )
    6568{
    66     psArray *files = psArrayAlloc(1); // Array with file names
     69    psArray *files = psArrayAlloc(1); ///< Array with file names
    6770    files->data[0] = psStringCopy(name);
    6871    psMetadataAddArray(config->arguments, PS_LIST_TAIL, file, 0, comment, files);
     
    7578    assert(config);
    7679
    77     psMetadata *arguments = psMetadataAlloc(); /** Command-line arguments */
     80    psMetadata *arguments = psMetadataAlloc(); ///< Command-line arguments
    7881    psMetadataAddStr(arguments, PS_LIST_TAIL, "-file1", 0, "First image", NULL);
    7982    psMetadataAddStr(arguments, PS_LIST_TAIL, "-op", 0, "Operation to perform", NULL);
     
    8891    bool isMask = psMetadataLookupBool(NULL, arguments, "-mask"); // Are we dealing with masks?
    8992    psMetadataAddBool(config->arguments, PS_LIST_TAIL, "MASK", 0, "Produce a mask image?", isMask);
    90     const char *inFilerule = isMask ? "PPARITH.INPUT.MASK" : "PPARITH.INPUT.IMAGE"; // Input file rule
    91     const char *outFilerule = isMask ? "PPARITH.OUTPUT.MASK" : "PPARITH.OUTPUT.IMAGE"; /** Output file rule */
     93    const char *inFilerule = isMask ? "PPARITH.INPUT.MASK" : "PPARITH.INPUT.IMAGE"; ///< Input file rule
     94    const char *outFilerule = isMask ? "PPARITH.OUTPUT.MASK" : "PPARITH.OUTPUT.IMAGE"; ///< Output file rule
    9295    psMetadataAddStr(config->arguments, PS_LIST_TAIL, "FILERULE.INPUT", 0,
    9396                     "File rule for input", inFilerule);
     
    9598                     "File rule for output", outFilerule);
    9699
    97     bool status = false;                /** Status for file definition */
     100    bool status = false;                ///< Status for file definition
    98101
    99102    // First file
    100     const char *name1 = psMetadataLookupStr(NULL, arguments, "-file1"); /** Name of first image */
     103    const char *name1 = psMetadataLookupStr(NULL, arguments, "-file1"); ///< Name of first image
    101104    if (!name1 || strlen(name1) == 0) {
    102105        psError(PS_ERR_UNEXPECTED_NULL, true, "No input image specified.");
     
    115118
    116119    // Second file is optional (won't be one for unary operations)
    117     const char *name2 = psMetadataLookupStr(NULL, arguments, "-file2"); /** Name of second image */
     120    const char *name2 = psMetadataLookupStr(NULL, arguments, "-file2"); ///< Name of second image
    118121    if (name2 && strlen(name2) > 0) {
    119122        fileList("INPUT2", name2, "Name of the second input image", config);
  • branches/eam_branch_20081230/ppArith/src/ppArithLoop.c

    r21229 r21239  
    66 *
    77 *  @author IfA
    8  *  @version $Revision: 1.6.28.1 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2009-01-30 01:39:11 $
     8 *  @version $Revision: 1.6.28.2 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2009-01-30 22:00:45 $
    1010 *  Copyright 2009 Institute for Astronomy, University of Hawaii
    1111 */
     
    2828    PS_ASSERT_PTR_NON_NULL(config, false);
    2929
    30     bool mdok;                          /** Status of MD lookup */
    31     const char *statsName = psMetadataLookupStr(&mdok, config->arguments, "STATS"); // Filename for statistics
    32     psMetadata *stats = NULL;           /** Container for statistics */
    33     FILE *statsFile = NULL;             /** File stream for statistics */
     30    bool mdok;                          ///< Status of MD lookup
     31    const char *statsName = psMetadataLookupStr(&mdok, config->arguments, "STATS"); ///< Filename for statistics
     32    psMetadata *stats = NULL;           ///< Container for statistics
     33    FILE *statsFile = NULL;             ///< File stream for statistics
    3434    if (statsName && strlen(statsName) > 0) {
    35         psString resolved = pmConfigConvertFilename(statsName, config, true, true); /** Resolved filename */
     35        psString resolved = pmConfigConvertFilename(statsName, config, true, true); ///< Resolved filename
    3636        statsFile = fopen(resolved, "w");
    3737        if (!statsFile) {
     
    4545    }
    4646
    47     const char *outName = psMetadataLookupStr(NULL, config->arguments, "FILERULE.OUTPUT"); /** Output filerule */
    48     pmFPAfile *output = psMetadataLookupPtr(NULL, config->files, outName); /** Output file */
     47    const char *outName = psMetadataLookupStr(NULL, config->arguments, "FILERULE.OUTPUT"); ///< Output filerule
     48    pmFPAfile *output = psMetadataLookupPtr(NULL, config->files, outName); ///< Output file
    4949    assert(output);                     // We added it earlier
    5050
    51     const char *inName = psMetadataLookupStr(NULL, config->arguments, "FILERULE.INPUT"); /** Input filerule */
    52     pmFPAfile *input1 = NULL, *input2 = NULL; /** Input files */
    53     psString fileRegex = NULL;   /** Regular expression to find input files */
     51    const char *inName = psMetadataLookupStr(NULL, config->arguments, "FILERULE.INPUT"); ///< Input filerule
     52    pmFPAfile *input1 = NULL, *input2 = NULL; ///< Input files
     53    psString fileRegex = NULL;   ///< Regular expression to find input files
    5454    psStringAppend(&fileRegex, "^%s$", inName);
    55     psMetadataIterator *iter = psMetadataIteratorAlloc(config->files, PS_LIST_HEAD, fileRegex); // Iterator
    56     psMetadataItem *item = psMetadataGetAndIncrement(iter); /** Item from iteration */
     55    psMetadataIterator *iter = psMetadataIteratorAlloc(config->files, PS_LIST_HEAD, fileRegex); ///< Iterator
     56    psMetadataItem *item = psMetadataGetAndIncrement(iter); ///< Item from iteration
    5757    input1 = item->data.V;
    5858    assert(input1);                     // It should be there!
     
    6363    psFree(iter);
    6464
    65     pmFPAview *view = pmFPAviewAlloc(0); /** Pointer into FPA hierarchya */
    66     pmHDU *lastHDU = NULL;              /** Last HDU that was updated */
     65    pmFPAview *view = pmFPAviewAlloc(0); ///< Pointer into FPA hierarchy
     66    pmHDU *lastHDU = NULL;              ///< Last HDU that was updated
    6767
    6868    // Iterate over the FPA hierarchy
     
    7171    }
    7272
    73     pmChip *outChip;                    /** Output chip of interest */
     73    pmChip *outChip;                    ///< Output chip of interest
    7474    while ((outChip = pmFPAviewNextChip(view, output->fpa, 1)) != NULL) {
    75         pmChip *inChip1 = pmFPAviewThisChip(view, input1->fpa); /** Input chip of interest */
    76         pmChip *inChip2 = input2 ? pmFPAviewThisChip(view, input2->fpa) : NULL; /** Input chip of interest */
     75        pmChip *inChip1 = pmFPAviewThisChip(view, input1->fpa); ///< Input chip of interest
     76        pmChip *inChip2 = input2 ? pmFPAviewThisChip(view, input2->fpa) : NULL; ///< Input chip of interest
    7777        if (inChip2 && ((!inChip1->file_exists && inChip2->file_exists) ||
    7878                        (inChip1->file_exists && !inChip2->file_exists))) {
     
    9090        }
    9191
    92         pmCell *outCell;                /** Cell of interest */
     92        pmCell *outCell;                ///< Cell of interest
    9393        while ((outCell = pmFPAviewNextCell(view, output->fpa, 1)) != NULL) {
    94             pmCell *inCell1 = pmFPAviewThisCell(view, input1->fpa); /** Input cell of interest */
    95             pmCell *inCell2 = input2 ? pmFPAviewThisCell(view, input2->fpa) : NULL; /** Input cell of interest */
     94            pmCell *inCell1 = pmFPAviewThisCell(view, input1->fpa); ///< Input cell of interest
     95            pmCell *inCell2 = input2 ? pmFPAviewThisCell(view, input2->fpa) : NULL; ///< Input cell of interest
    9696            if (inCell2 && ((!inCell1->file_exists && inCell2->file_exists) ||
    9797                            (inCell1->file_exists && !inCell2->file_exists))) {
     
    117117            }
    118118
    119             pmReadout *outRO;           // Readout of interest
     119            pmReadout *outRO;           ///< Readout of interest
    120120            while ((outRO = pmFPAviewNextReadout(view, output->fpa, 1))) {
    121121                if (!pmFPAfileIOChecks(config, view, PM_FPA_BEFORE)) {
    122122                    return false;
    123123                }
    124                 pmReadout *inRO1 = pmFPAviewThisReadout(view, input1->fpa);/** Input readout of interest */
     124                pmReadout *inRO1 = pmFPAviewThisReadout(view, input1->fpa);///< Input readout of interest
    125125                pmReadout *inRO2 = input2 ? pmFPAviewThisReadout(view, input2->fpa) :
    126                     NULL;/** Input readout of interest */
     126                    NULL;///< Input readout of interest
    127127
    128128                if (inRO2 && ((!inRO1->data_exists && inRO2->data_exists) ||
  • branches/eam_branch_20081230/ppArith/src/ppArithReadout.c

    r21229 r21239  
    66 *
    77 *  @author IfA
    8  *  @version $Revision: 1.2.32.2 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2009-01-30 01:39:32 $
     8 *  @version $Revision: 1.2.32.3 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2009-01-30 22:00:45 $
    1010 *  Copyright 2009 Institute for Astronomy, University of Hawaii
    1111 */
     
    2929    PS_ASSERT_PTR_NON_NULL(view, false);
    3030
    31     bool mdok;                          /** Status of MD lookup */
     31    bool mdok;                          ///< Status of MD lookup
    3232    bool isMask = psMetadataLookupBool(&mdok, config->arguments, "MASK");
    3333
    34     psImage *inImage1;  /** Input image 1 */
    35     psImage *outImage;  /** Output image */
     34    psImage *inImage1;  ///< Input image 1
     35    psImage *outImage;  ///< Output image
    3636    if (isMask) {
    3737        inImage1 = input1->mask;
     
    5454    PS_ASSERT_IMAGE_NON_NULL(inImage1, false);
    5555
    56     psImage *inImage2 = NULL;           /** Input image 2 */
     56    psImage *inImage2 = NULL;           ///< Input image 2
    5757    if (input2) {
    5858        inImage2 = isMask ? input2->mask : input2->image;
     
    7373
    7474    // Look up appropriate values
    75     const char *op = psMetadataLookupStr(NULL, config->arguments, "OPERATION"); // Operation to perform
     75    const char *op = psMetadataLookupStr(NULL, config->arguments, "OPERATION"); ///< Operation to perform
    7676
    7777    if (input2) {
  • branches/eam_branch_20081230/ppArith/src/ppArithVersion.c

    r21229 r21239  
    66 *
    77 *  @author IfA
    8  *  @version $Revision: 1.1.32.1 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2009-01-30 01:39:49 $
     8 *  @version $Revision: 1.1.32.2 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2009-01-30 22:00:45 $
    1010 *  Copyright 2009 Institute for Astronomy, University of Hawaii
    1111 */
     
    2222#include "ppArith.h"
    2323
    24 static const char *cvsTag = "$Name: not supported by cvs2svn $";/** CVS tag name */
     24static const char *cvsTag = "$Name: not supported by cvs2svn $";///< CVS tag name
    2525
    2626psString ppArithVersion(void)
    2727{
    28     psString version = NULL;            /** Version, to return */
     28    psString version = NULL;            ///< Version, to return
    2929    psStringAppend(&version, "%s-%s",PACKAGE_NAME,PACKAGE_VERSION);
    3030    return version;
     
    3333psString ppArithVersionLong(void)
    3434{
    35     psString version = ppArithVersion(); /** Version, to return */
    36     psString tag = psStringStripCVS(cvsTag, "Name"); // CVS tag
     35    psString version = ppArithVersion(); ///< Version, to return
     36    psString tag = psStringStripCVS(cvsTag, "Name"); ///< CVS tag
    3737    psStringAppend(&version, " (cvs tag %s) %s, %s", tag, __DATE__, __TIME__);
    3838    psFree(tag);
     
    4545    PS_ASSERT_METADATA_NON_NULL(metadata,);
    4646
    47     psString pslib = psLibVersionLong();/** psLib version */
    48     psString psmodules = psModulesVersionLong(); /** psModules version */
    49     psString ppStats = ppStatsVersionLong(); /** ppStats version */
    50     psString ppArith = ppArithVersionLong(); /** ppArith version */
     47    psString pslib = psLibVersionLong();///< psLib version
     48    psString psmodules = psModulesVersionLong(); ///< psModules version
     49    psString ppStats = ppStatsVersionLong(); ///< ppStats version
     50    psString ppArith = ppArithVersionLong(); ///< ppArith version
    5151
    52     psTime *time = psTimeGetNow(PS_TIME_TAI); /** The time now */
    53     psString timeString = psTimeToISO(time); /** The time in an ISO string */
     52    psTime *time = psTimeGetNow(PS_TIME_TAI); ///< The time now
     53    psString timeString = psTimeToISO(time); ///< The time in an ISO string
    5454    psFree(time);
    55     psString head = NULL;               /** Head string */
     55    psString head = NULL;               ///< Head string
    5656    psStringAppend(&head, "ppArith processing at %s. Component information:", timeString);
    5757    psFree(timeString);
Note: See TracChangeset for help on using the changeset viewer.