IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 19, 2005, 5:10:19 PM (21 years ago)
Author:
eugene
Message:

modifications to use CATMODE, CATFORMAT

Location:
trunk/Ohana/src/relphot
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/relphot/include/relphot.h

    r4810 r4828  
    4040char   GSCFILE[256];
    4141char   CATDIR[256];
     42char   CATMODE[16];    /* raw, mef, split, mysql */
     43char   CATFORMAT[16];  /* internal, elixir, loneos, panstarrs */
    4244char   CameraConfig[256];
    4345
  • trunk/Ohana/src/relphot/src/ConfigInit.c

    r4796 r4828  
    3838  GetConfig (config, "GSCFILE",                "%s",  0, GSCFILE);
    3939  GetConfig (config, "CATDIR",                 "%s",  0, CATDIR);
     40  ScanConfig (config, "CATMODE",                "%s",  0, CATMODE);
     41  ScanConfig (config, "CATFORMAT",              "%s",  0, CATFORMAT);
    4042  GetConfig (config, "PHOTCODE_FILE",          "%s",  0, PhotCodeFile);
    4143  GetConfig (config, "ZERO_PT",                "%lf", 0, &ZERO_POINT);
     
    4547  GetConfig (config, "RELPHOT_GRID_BINNING",   "%d",  0, &RELPHOT_GRID_BINNING);
    4648  GetConfig (config, "CAMERA_CONFIG",          "%s",  0, CameraConfig);
     49
     50  if (*CATMODE == 0) strcpy (CATMODE, "RAW");
     51  if (*CATFORMAT == 0) strcpy (CATFORMAT, "ELIXIR");
    4752
    4853  if (!LoadPhotcodes (PhotCodeFile)) {
  • trunk/Ohana/src/relphot/src/gcatalog.c

    r4796 r4828  
    44 
    55  char mode;
     6
     7  /* no autodetect for CATMODE yet */
     8  strcpy (catalog[0].catmode, CATMODE);
    69
    710  if (FINAL) {
  • trunk/Ohana/src/relphot/src/wcatalog.c

    r2486 r4828  
    33void wcatalog (Catalog *catalog) {
    44 
    5   fits_modify (&catalog[0].header, "NRPHOT", "%t", 1, TRUE);
     5  /* set catalog format (elixir, loneos, etc) */
     6  if (!strcmp (CATFORMAT, "INTERNAL")) {
     7    sprintf (catalog[0].average_format, "DVO_AVERAGE");
     8    sprintf (catalog[0].measure_format, "DVO_MEASURE");
     9  } else {
     10    sprintf (catalog[0].average_format, "DVO_AVERAGE_%s", CATFORMAT);
     11    sprintf (catalog[0].measure_format, "DVO_MEASURE_%s", CATFORMAT);
     12  }
    613
    7   save_catalog (catalog, VERBOSE);
     14  if (!save_catalog (catalog, VERBOSE)) {
     15    fprintf (stderr, "ERROR: failure saving catalog\n");
     16    exit (1);
     17  }
    818
    919  if (catalog[0].Naverage) {
     
    2333    catalog[0].Nsecfilt = 0;
    2434  }
     35  fits_free_header (&catalog[0].header);
    2536}
Note: See TracChangeset for help on using the changeset viewer.