MOONS Pipeline Reference Manual 0.13.1
moo_telluric.h
1/*
2 * This file is part of the MOONS Pipeline
3 * Copyright (C) 2002-2016 European Southern Observatory
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 */
19
20#ifndef MOO_TELLURIC_H
21#define MOO_TELLURIC_H
22
23/*-----------------------------------------------------------------------------
24 Includes
25 -----------------------------------------------------------------------------*/
26#include <cpl.h>
27#include <hdrl.h>
28#include "moo_scilist.h"
35#define MOO_TELLURIC_EXT_RI "RI"
36#define MOO_TELLURIC_EXT_YJ "YJ"
37#define MOO_TELLURIC_EXT_H "H"
38#define MOO_TELLURIC_EXT_STANDARD_TABLE "STANDARD_TABLE"
39#define MOO_TELLURIC_TABLE_INDEXRBN "INDEXRBN"
40#define MOO_TELLURIC_TABLE_SPECTRO "SPECTRO"
41#define MOO_TELLURIC_TABLE_BAND "BAND"
42#define MOO_TELLURIC_TABLE_TELLURIC "TELLURIC"
43#define MOO_TELLURIC_WAVE "WAVE"
44#define MOO_TELLURIC_TELLURIC "TELLURIC"
45
46typedef struct
47{
48 cpl_propertylist *primary_header;
49 cpl_image *data[3];
50 cpl_propertylist *data_header[3];
51 cpl_table *telluric_table;
52} moo_telluric;
53
54/*-----------------------------------------------------------------------------
55 Functions prototypes
56 -----------------------------------------------------------------------------*/
57moo_telluric *moo_telluric_new(void);
58moo_telluric *moo_telluric_create(moo_scilist *scilist, int badpix_level);
59moo_telluric *moo_telluric_create_from_rbn(moo_rbn *rbn);
60void moo_telluric_delete(moo_telluric *telluric);
61cpl_error_code moo_telluric_set_image(moo_telluric *self,
63 cpl_image *t);
64cpl_error_code moo_telluric_set_header(moo_telluric *self,
66 cpl_propertylist *t);
67cpl_image *moo_telluric_get_image(moo_telluric *self, moo_detector_type type);
68int moo_telluric_get_index(moo_telluric *self,
69 int idrbn,
70 int spectro,
71 const char *band);
72void moo_telluric_save(moo_telluric *self, const char *filename);
73moo_telluric *moo_telluric_load(const cpl_frame *frame);
75#endif
enum _moo_detector_type_ moo_detector_type
The type code type.
Definition: moo_detector.h:64
moo_telluric * moo_telluric_create(moo_scilist *scilist, int badpix_level)
Prepare TELLURIC for SCI frame.
Definition: moo_telluric.c:141
moo_telluric * moo_telluric_load(const cpl_frame *frame)
Load a TELLURIC frame and create a moo_telluric.
Definition: moo_telluric.c:405
int moo_telluric_get_index(moo_telluric *self, int idrbn, int spectro, const char *band)
Get the index of the telluric for a given indexrbn.
Definition: moo_telluric.c:463
const char * moo_telluric_get_band(moo_detector_type type)
Get the band of the telluric
Definition: moo_telluric.c:511
cpl_image * moo_telluric_get_image(moo_telluric *self, moo_detector_type type)
Get a telluric image from TELLURIC.
Definition: moo_telluric.c:116
cpl_error_code moo_telluric_set_image(moo_telluric *self, moo_detector_type type, cpl_image *t)
assign image in moo_telluric
Definition: moo_telluric.c:87
void moo_telluric_delete(moo_telluric *telluric)
Delete a moo_telluric.
Definition: moo_telluric.c:334
void moo_telluric_save(moo_telluric *self, const char *filename)
Save a moo_telluric to a FITS file.
Definition: moo_telluric.c:367
moo_telluric * moo_telluric_new(void)
Create a new moo_telluric.
Definition: moo_telluric.c:67
moo_telluric * moo_telluric_create_from_rbn(moo_rbn *rbn)
Prepare TELLURIC for SCI frame.
Definition: moo_telluric.c:259