IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 6, 2005, 6:11:02 AM (21 years ago)
Author:
eugene
Message:

added CLOSEST match method, added SPLIT table support, made catmode and catformat case-insensitive, added -nosort concept, cleaned find_matches

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/addstar/src/image-db.c

    r5014 r5229  
    4040
    4141  /* set the recommended mode */
    42   if (!strcmp (CATMODE, "RAW")) {
     42  db[0].mode = DVO_MODE_UNDEF;
     43  if (!strcasecmp (CATMODE, "RAW")) {
    4344    /* make header a fake image */
    4445    db[0].header.bitpix   = 16;
     
    4950    db[0].mode = DVO_MODE_RAW;
    5051  }
    51 
    52   if (!strcmp (CATMODE, "MEF") || !strcmp (CATMODE, "SPLIT")) {
     52  if (!strcasecmp (CATMODE, "MEF") || !strcasecmp (CATMODE, "SPLIT")) {
    5353    db[0].header.extend   = TRUE;
    5454    fits_create_header (&db[0].header);
    5555    db[0].mode = DVO_MODE_MEF;
    5656  }
     57  if (db[0].mode == DVO_MODE_UNDEF) {
     58    fprintf (stderr, "invalid output catalog mode\n");
     59    exit (1);
     60  }
    5761
    5862  /* set the recommended format */
    5963  db[0].format = DVO_FORMAT_UNDEF;
    60   if (!strcmp (CATFORMAT, "INTERNAL"))  db[0].format = DVO_FORMAT_INTERNAL;
    61   if (!strcmp (CATFORMAT, "LONEOS"))    db[0].format = DVO_FORMAT_LONEOS;
    62   if (!strcmp (CATFORMAT, "ELIXIR"))    db[0].format = DVO_FORMAT_ELIXIR;
    63   if (!strcmp (CATFORMAT, "PANSTARRS")) db[0].format = DVO_FORMAT_PANSTARRS;
     64  if (!strcasecmp (CATFORMAT, "INTERNAL"))  db[0].format = DVO_FORMAT_INTERNAL;
     65  if (!strcasecmp (CATFORMAT, "LONEOS"))    db[0].format = DVO_FORMAT_LONEOS;
     66  if (!strcasecmp (CATFORMAT, "ELIXIR"))    db[0].format = DVO_FORMAT_ELIXIR;
     67  if (!strcasecmp (CATFORMAT, "PANSTARRS")) db[0].format = DVO_FORMAT_PANSTARRS;
    6468  if (db[0].format == DVO_FORMAT_UNDEF) {
    6569    fprintf (stderr, "invalid output catalog format\n");
Note: See TracChangeset for help on using the changeset viewer.