IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Apr 23, 2015, 2:41:17 PM (11 years ago)
Author:
eugene
Message:

adding UKIRT ingest

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20150419/Ohana/src/addstar/src/MatchHeaders.c

    r37967 r38167  
    3939  }
    4040
     41  // check for ukirt mode
     42  if (Nheaders == 5) {
     43    int myMode = GetFileMode (headers[1]);
     44    if (myMode != UKIRT_OBJ) goto other_modes;
     45    for (i = 2; i < 5; i++) {
     46      myMode = GetFileMode (headers[i]);
     47      if (myMode != UKIRT_OBJ) {
     48        fprintf (stderr, "inconsistent headers for UKIRT\n");
     49        exit (2);
     50      }
     51    }
     52
     53    for (i = 1; i < Nheaders; i++) {
     54      extsize[0][i] = headers[i][0].datasize + gfits_data_size (headers[i]);
     55
     56      gfits_scan (headers[i], ExtnameKeyword, "%s", 1, extname);
     57      headerSets[Nimage].exttype = strcreate ("UKIRT_OBJ");
     58      headerSets[Nimage].extdata = strcreate (extname);
     59      headerSets[Nimage].exthead = strcreate (extname);
     60      headerSets[Nimage].extxrad = NULL;
     61      headerSets[Nimage].extnum_data = i;
     62      headerSets[Nimage].extnum_head = i;
     63      headerSets[Nimage].extnum_xrad = -1;
     64      Nimage ++;
     65    }
     66    *nimage = Nimage;
     67    return headerSets;
     68  }
     69
     70other_modes:
     71
    4172  // now examine the headers, count the table entries, find corresponding headers
    4273  for (i = 0; i < Nheaders; i++) {
     
    71102    if (!strcmp (exttype, "PS1_DV4")) goto keep;
    72103    if (!strcmp (exttype, "PS1_DV5")) goto keep;
     104
    73105    continue;
    74106
Note: See TracChangeset for help on using the changeset viewer.