IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 5, 2008, 2:39:59 PM (18 years ago)
Author:
Paul Price
Message:

Adding configuration dumping. Required reorganisation of how recipe values get into the program. Formerly, the command-line and recipe values were parsed and the result was put on config->arguments. Now, we want whatever was altered by the command-line to be reflected in the recipe (which is dumped), so using the recipe as the storage. Not yet tested, but will do so soon.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/pswarp/src/pswarp.c

    r17781 r18924  
    22
    33static void usage (void) {
    4     fprintf (stderr, "USAGE: pswarp [-file image(s)] [-list imagelist] [options] (output) (skycell)\n");
    5     fprintf (stderr, "  options:\n");
    6     fprintf (stderr, "    [-astrom astrom.cmp] : provide an alternative astrometry calibration\n");
    7     fprintf (stderr, "    [-mask mask.fits] : provide a corresponding mask image\n");
    8     fprintf (stderr, "    [-weight weight.fits] : provide a corresponding weight image (pixel varience)\n");
     4    fprintf(stderr, "USAGE: pswarp [-file image(s)] [-list imagelist] [options] (output) (skycell)\n");
     5    fprintf(stderr, "  options:\n");
     6    fprintf(stderr, "    [-astrom astrom.cmp] : provide an alternative astrometry calibration\n");
     7    fprintf(stderr, "    [-mask mask.fits] : provide a corresponding mask image\n");
     8    fprintf(stderr, "    [-weight weight.fits] : provide a corresponding weight image (pixel varience)\n");
    99    psErrorStackPrint(stderr, "\n");
    1010    exit (2);
     
    2424    if (!config) usage();
    2525
    26     if (!pswarpOptions(config)) {
    27         psErrorStackPrint(stderr, "error parsing options\n");
    28         exit(1);
    29     }
    30 
    3126    // load identify the data sources
    3227    if (!pswarpParseCamera(config)) {
    3328        psErrorStackPrint(stderr, "error setting up the camera\n");
    34         exit (1);
     29        exit(PS_EXIT_CONFIG_ERROR);
     30    }
     31
     32    if (!pswarpOptions(config)) {
     33        psErrorStackPrint(stderr, "error parsing options\n");
     34        exit(PS_EXIT_SYS_ERROR);
    3535    }
    3636
     
    3838    if (!pswarpDefine(config)) {
    3939        psErrorStackPrint(stderr, "error loading output definition\n");
    40         exit (1);
     40        exit(PS_EXIT_CONFIG_ERROR);
    4141    }
    4242
     
    4444    if (!pswarpLoop(config)) {
    4545        psErrorStackPrint(stderr, "error warping data\n");
    46         exit (1);
     46        exit(PS_EXIT_DATA_ERROR);
    4747    }
    4848
     
    5050    pswarpCleanup(config);
    5151    psLibFinalize();
    52     exit(EXIT_SUCCESS);
     52    exit(PS_EXIT_SUCCESS);
    5353}
Note: See TracChangeset for help on using the changeset viewer.