~ubuntu-branches/debian/jessie/eso-midas/jessie

« back to all changes in this revision

Viewing changes to incl/fitsdkw.h

  • Committer: Package Import Robot
  • Author(s): Ole Streicher
  • Date: 2014-04-22 14:44:58 UTC
  • Revision ID: package-import@ubuntu.com-20140422144458-okiwi1assxkkiz39
Tags: upstream-13.09pl1.2+dfsg
ImportĀ upstreamĀ versionĀ 13.09pl1.2+dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* @(#)fitsdkw.h        19.2 (ESO-IPG) 05/05/03 08:56:09 */
 
2
/*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 
3
.COPYRIGHT    (c)  1992   European Southern Observatory
 
4
.LANGUAGE     C
 
5
.IDENT        fitsdkw.h
 
6
.AUTHOR       P.Grosbol   ESO/IPG
 
7
.KEYWORDS     FITS, keywords, MIDAS descriptors
 
8
.PURPOSE      define mapping between MIDAS descriptors and
 
9
              FITS keywords when writting a FITS header
 
10
.VERSION      1.0   1988-Nov-23 :  Creation,  PJG
 
11
.VERSION      1.1   1989-Jun-13 :  Add ROTA keyword,  PJG
 
12
.VERSION      1.2   1990-Feb-02 :  Modify for hierachical keyword, PJG
 
13
.VERSION      1.3   1990-Nov-07 :  Include more basic keywords, PJG
 
14
.VERSION      1.4   1991-Feb-18 :  Add FILENAME and DATANULL, PJG
 
15
.VERSION      1.5   1991-Mar-24 :  Add TBLOFFST + ESO_LOG, PJG
 
16
.VERSION      1.6   1992-Jun-05 :  Map also O_POS+O_TIME etc., PJG
 
17
.VERSION      1.7   1992-Sep-10 :  Map also O_AIRM+AIRMASS, PJG
 
18
 
 
19
 030502         last modif
 
20
 
 
21
--------------------------------------------------------------------*/
 
22
 
 
23
#define     NCTL         0         /* no mapping action             */
 
24
#define     LCTL         1         /* line feed control             */
 
25
#define     CCTL         2         /* Comment/history control       */
 
26
#define     SCTL         3         /* skip trailing space control   */
 
27
#define     HCTL         4         /* hierarchical keyword control  */
 
28
#define     DCTL         5         /* Date keyword control          */
 
29
#define     ZCTL         6         /* Zero control                  */
 
30
#define     TCTL         7         /* Time control - hour->sec      */
 
31
 
 
32
typedef struct {                   /* keyword name for descriptor   */
 
33
                 int           no; /* element no. in descriptor     */
 
34
                 char         *kw; /* prime level keyword name      */
 
35
                 int          ctl; /* store control type            */
 
36
               } DTOKW;
 
37
 
 
38
typedef struct {                   /* descriptor to keyword map     */
 
39
                 char       *desc; /* MIDAS descriotor name         */
 
40
                 DTOKW       *dtk; /* pointer to keyword name       */
 
41
               } DKMAP;
 
42
 
 
43
static  DTOKW   idtkw[] = { {-1,"OBJECT" , SCTL}, { 0,"",        NCTL} };
 
44
static  DTOKW   hiskw[] = { {-1,"HISTORY", CCTL}, { 0,"",        NCTL} };
 
45
static  DTOKW   comkw[] = { {-1,"COMMENT", CCTL}, { 0,"",        NCTL} };
 
46
static  DTOKW   esokw[] = { {-1,"ESO-LOG", CCTL}, { 0,"",        NCTL} };
 
47
static  DTOKW   hiekw[] = { {-1,"HIERARCH",CCTL}, { 0,"",        NCTL} };
 
48
static  DTOKW   inskw[] = { {-1,"INSTRUME",SCTL}, { 0,"",        NCTL} };
 
49
static  DTOKW   telkw[] = { {-1,"TELESCOP",SCTL}, { 0,"",        NCTL} };
 
50
static  DTOKW   autkw[] = { {-1,"AUTHOR",  SCTL}, { 0,"",        NCTL} };
 
51
static  DTOKW   refkw[] = { {-1,"REFERENC",SCTL}, { 0,"",        NCTL} };
 
52
static  DTOKW   radkw[] = { {-1,"RADECSYS",SCTL}, { 0,"",        NCTL} };
 
53
static  DTOKW   obskw[] = { {-1,"OBSERVER",SCTL}, { 0,"",        NCTL} };
 
54
static  DTOKW   airkw[] = { { 1,"AIRMASS", ZCTL}, { 0,"",        NCTL} };
 
55
static  DTOKW   expkw[] = { { 1,"EXPTIME", NCTL}, { 0,"",        NCTL} };
 
56
static  DTOKW   rakw[]  = { { 1,"RA",      NCTL}, { 0,"",        NCTL} };
 
57
static  DTOKW   deckw[] = { { 1,"DEC",     NCTL}, { 0,"",        NCTL} };
 
58
static  DTOKW   equkw[] = { { 1,"EQUINOX", ZCTL}, { 0,"",        NCTL} };
 
59
static  DTOKW   poskw[] = { { 1,"RA",      NCTL}, { 2,"DEC",     NCTL},
 
60
                            { 3,"EQUINOX", ZCTL}, { 0,"",        NCTL} };
 
61
static  DTOKW   timkw[] = { { 1,"DATE-OBS",DCTL}, { 4,"MJD-OBS", ZCTL},
 
62
                            { 5,"TM-START",TCTL}, { 7,"EXPTIME", NCTL}, 
 
63
                            { 0,"",        NCTL} };
 
64
static  DTOKW   oamkw[] = { { 1,"AIRMASS", ZCTL}, { 0,"",        NCTL} };
 
65
 
 
66
static  DKMAP  dkm[] = {
 
67
         {"IDENT"   , idtkw},
 
68
         {"HISTORY" , hiskw},
 
69
         {"COMMENT" , comkw},
 
70
         {"ESO_LOG" , esokw},
 
71
         {"EXPTIME" , expkw},
 
72
         {"INSTRUME", inskw},
 
73
         {"TELESCOP", telkw},
 
74
         {"AIRMASS" , airkw},
 
75
         {"OBSERVER", obskw},
 
76
         {"HIERARCH", hiekw},
 
77
         {"AUTHOR"  , autkw},
 
78
         {"REFERENC", refkw},
 
79
         {"RADECSYS", radkw},
 
80
         {"RA"      ,  rakw},
 
81
         {"DEC"     , deckw},
 
82
         {"EQUINOX" , equkw},
 
83
         {"O_POS"   , poskw},
 
84
         {"O_TIME"  , timkw},
 
85
         {"O_AIRM"  , oamkw},
 
86
         {"NPIX"    , (DTOKW *) 0},
 
87
         {"NAXIS"   , (DTOKW *) 0},
 
88
         {"CUNIT"   , (DTOKW *) 0},
 
89
         {"CRVAL"   , (DTOKW *) 0},
 
90
         {"REFPIX"  , (DTOKW *) 0},
 
91
         {"ROTA"    , (DTOKW *) 0},
 
92
         {"STEP"    , (DTOKW *) 0},
 
93
         {"START"   , (DTOKW *) 0},
 
94
         {"FILENAME", (DTOKW *) 0},
 
95
         {"DATE"    , (DTOKW *) 0},
 
96
         {"ORIGIN"  , (DTOKW *) 0},
 
97
         {"DATANULL", (DTOKW *) 0},
 
98
         {"TBLENGTH", (DTOKW *) 0},
 
99
         {"TBLCONTR", (DTOKW *) 0},
 
100
         {"TSELTABL", (DTOKW *) 0},
 
101
         {"TBLOFFST", (DTOKW *) 0},
 
102
         {(char *) 0,(DTOKW *) 0} };