MOONS Pipeline Reference Manual 0.13.1
moo_qc.c
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#ifdef HAVE_CONFIG_H
21#include <config.h>
22#endif
23
24/*-----------------------------------------------------------------------------
25 Includes
26 -----------------------------------------------------------------------------*/
27
28#include <cpl.h>
29#include <string.h>
30#include "moo_detector.h"
31#include "moo_utils.h"
32#include "moo_qc.h"
33
34/*----------------------------------------------------------------------------*/
39/*----------------------------------------------------------------------------*/
40
43/*-----------------------------------------------------------------------------
44 Function codes
45 -----------------------------------------------------------------------------*/
46
47
48/*----------------------------------------------------------------------------*/
60/*----------------------------------------------------------------------------*/
61cpl_error_code
62moo_qc_set_ncrh(cpl_propertylist *plist, int val)
63{
64 const char *key = MOONS_QC_CRH_NUMBER;
65 const char *comment = MOONS_QC_CRH_NUMBER_C;
66
67 cpl_error_code status = CPL_ERROR_NONE;
68
69 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
70 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
71 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
72 status);
73moo_try_cleanup:
74 return status;
75}
76
77/*----------------------------------------------------------------------------*/
89/*----------------------------------------------------------------------------*/
90cpl_error_code
91moo_qc_set_ncrh_tot(cpl_propertylist *plist, int val)
92{
93 const char *key = MOONS_QC_CRH_TOT;
94 const char *comment = MOONS_QC_CRH_TOT_C;
95
96 cpl_error_code status = CPL_ERROR_NONE;
97
98 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
99 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
100 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
101 status);
102moo_try_cleanup:
103 return status;
104}
105
106/*----------------------------------------------------------------------------*/
118/*----------------------------------------------------------------------------*/
119cpl_error_code
120moo_qc_set_ncrh_avg(cpl_propertylist *plist, float val)
121{
122 const char *key = MOONS_QC_CRH_AVG;
123 const char *comment = MOONS_QC_CRH_AVG_C;
124
125 cpl_error_code status = CPL_ERROR_NONE;
126
127 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
128 moo_ensure_status(cpl_propertylist_append_float(plist, key, val), status);
129 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
130 status);
131moo_try_cleanup:
132 return status;
133}
134
135/*----------------------------------------------------------------------------*/
147/*----------------------------------------------------------------------------*/
148cpl_error_code
149moo_qc_set_ncom(cpl_propertylist *plist, int val)
150{
151 const char *key = MOONS_QC_NCOM;
152 const char *comment = MOONS_QC_NCOM_C;
153
154 cpl_error_code status = CPL_ERROR_NONE;
155
156 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
157 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
158 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
159 status);
160moo_try_cleanup:
161 return status;
162}
163
164/*----------------------------------------------------------------------------*/
178/*----------------------------------------------------------------------------*/
179cpl_error_code
180moo_qc_set_mbias_avg(cpl_propertylist *plist, int i, double val)
181{
182 cpl_error_code status = CPL_ERROR_NONE;
183
184 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
185
186 char *key = cpl_sprintf(MOONS_QC_MBIAS_AVG, i);
187
188 if (key != NULL) {
189 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
190 status);
191 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
192 MOONS_QC_MBIAS_AVG_C),
193 status);
194 }
195 else {
196 status = cpl_error_get_code();
197 }
198moo_try_cleanup:
199 if (key != NULL) {
200 cpl_free(key);
201 }
202 return status;
203}
204
205/*----------------------------------------------------------------------------*/
219/*----------------------------------------------------------------------------*/
220cpl_error_code
221moo_qc_set_mbias_med(cpl_propertylist *plist, int i, double val)
222{
223 cpl_error_code status = CPL_ERROR_NONE;
224
225 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
226
227 char *key = cpl_sprintf(MOONS_QC_MBIAS_MED, i);
228
229 if (key != NULL) {
230 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
231 status);
232 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
233 MOONS_QC_MBIAS_MED_C),
234 status);
235 }
236 else {
237 status = cpl_error_get_code();
238 }
239moo_try_cleanup:
240 if (key != NULL) {
241 cpl_free(key);
242 }
243 return status;
244}
245
246/*----------------------------------------------------------------------------*/
260/*----------------------------------------------------------------------------*/
261cpl_error_code
262moo_qc_set_mbias_rms(cpl_propertylist *plist, int i, double val)
263{
264 cpl_error_code status = CPL_ERROR_NONE;
265
266 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
267
268 char *key = cpl_sprintf(MOONS_QC_MBIAS_RMS, i);
269
270 if (key != NULL) {
271 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
272 status);
273 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
274 MOONS_QC_MBIAS_RMS_C),
275 status);
276 }
277 else {
278 status = cpl_error_get_code();
279 }
280moo_try_cleanup:
281 if (key != NULL) {
282 cpl_free(key);
283 }
284 return status;
285}
286
287/*----------------------------------------------------------------------------*/
301/*----------------------------------------------------------------------------*/
302cpl_error_code
303moo_qc_set_mbias_mad(cpl_propertylist *plist, int i, double val)
304{
305 cpl_error_code status = CPL_ERROR_NONE;
306
307 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
308
309 char *key = cpl_sprintf(MOONS_QC_MBIAS_MAD, i);
310
311 if (key != NULL) {
312 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
313 status);
314 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
315 MOONS_QC_MBIAS_MAD_C),
316 status);
317 }
318 else {
319 status = cpl_error_get_code();
320 }
321moo_try_cleanup:
322 if (key != NULL) {
323 cpl_free(key);
324 }
325 return status;
326}
327
328/*----------------------------------------------------------------------------*/
342/*----------------------------------------------------------------------------*/
343cpl_error_code
344moo_qc_set_ron_raw(cpl_propertylist *plist, int i, double val)
345{
346 cpl_error_code status = CPL_ERROR_NONE;
347
348 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
349
350 char *key = cpl_sprintf(MOONS_QC_RON_RAW, i);
351
352 if (key != NULL) {
353 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
354 status);
355 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
356 MOONS_QC_RON_RAW_C),
357 status);
358 }
359 else {
360 status = cpl_error_get_code();
361 }
362moo_try_cleanup:
363 if (key != NULL) {
364 cpl_free(key);
365 }
366 return status;
367}
368
369/*----------------------------------------------------------------------------*/
383/*----------------------------------------------------------------------------*/
384cpl_error_code
385moo_qc_set_ron_master(cpl_propertylist *plist, int i, double val)
386{
387 cpl_error_code status = CPL_ERROR_NONE;
388
389 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
390
391 char *key = cpl_sprintf(MOONS_QC_RON_MASTER, i);
392
393 if (key != NULL) {
394 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
395 status);
396 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
397 MOONS_QC_RON_MASTER_C),
398 status);
399 }
400 else {
401 status = cpl_error_get_code();
402 }
403moo_try_cleanup:
404 if (key != NULL) {
405 cpl_free(key);
406 }
407 return status;
408}
409
410/*----------------------------------------------------------------------------*/
422/*----------------------------------------------------------------------------*/
423cpl_error_code
424moo_qc_set_mdark_nhot(cpl_propertylist *plist, int val)
425{
426 const char *key = MOONS_QC_MDARK_NHOT;
427 const char *comment = MOONS_QC_MDARK_NHOT_C;
428
429 cpl_error_code status = CPL_ERROR_NONE;
430
431 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
432 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
433 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
434 status);
435moo_try_cleanup:
436 return status;
437}
438
439/*----------------------------------------------------------------------------*/
451/*----------------------------------------------------------------------------*/
452cpl_error_code
453moo_qc_set_mdark_avg(cpl_propertylist *plist, double val)
454{
455 const char *key = MOONS_QC_MDARK_AVG;
456 const char *comment = MOONS_QC_MDARK_AVG_C;
457
458 cpl_error_code status = CPL_ERROR_NONE;
459
460 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
461 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
462 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
463 status);
464moo_try_cleanup:
465 return status;
466}
467/*----------------------------------------------------------------------------*/
479/*----------------------------------------------------------------------------*/
480cpl_error_code
481moo_qc_set_mdark_normalise_factor(cpl_propertylist *plist, double val)
482{
483 const char *key = MOONS_QC_MDARK_NORMALISE_FACTOR;
484 const char *comment = MOONS_QC_MDARK_NORMALISE_FACTOR_C;
485
486 cpl_error_code status = CPL_ERROR_NONE;
487
488 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
489 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
490 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
491 status);
492moo_try_cleanup:
493 return status;
494}
495/*----------------------------------------------------------------------------*/
507/*----------------------------------------------------------------------------*/
508cpl_error_code
509moo_qc_set_mdark_med(cpl_propertylist *plist, double val)
510{
511 const char *key = MOONS_QC_MDARK_MED;
512 const char *comment = MOONS_QC_MDARK_MED_C;
513
514 cpl_error_code status = CPL_ERROR_NONE;
515
516 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
517 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
518 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
519 status);
520moo_try_cleanup:
521 return status;
522}
523
524/*----------------------------------------------------------------------------*/
536/*----------------------------------------------------------------------------*/
537cpl_error_code
538moo_qc_set_mdark_rms(cpl_propertylist *plist, double val)
539{
540 const char *key = MOONS_QC_MDARK_RMS;
541 const char *comment = MOONS_QC_MDARK_RMS_C;
542
543 cpl_error_code status = CPL_ERROR_NONE;
544
545 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
546 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
547 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
548 status);
549moo_try_cleanup:
550 return status;
551}
552
553/*----------------------------------------------------------------------------*/
565/*----------------------------------------------------------------------------*/
566cpl_error_code
567moo_qc_set_mdark_current(cpl_propertylist *plist, double val)
568{
569 const char *key = MOONS_QC_MDARK_CURRENT;
570 const char *comment = MOONS_QC_MDARK_CURRENT_C;
571
572 cpl_error_code status = CPL_ERROR_NONE;
573
574 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
575 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
576 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
577 status);
578moo_try_cleanup:
579 return status;
580}
581
582/*----------------------------------------------------------------------------*/
594/*----------------------------------------------------------------------------*/
595cpl_error_code
596moo_qc_set_residy_med(cpl_propertylist *plist, double val)
597{
598 const char *key = MOONS_QC_RESIDY_MED;
599 const char *comment = MOONS_QC_RESIDY_MED_C;
600
601 cpl_error_code status = CPL_ERROR_NONE;
602
603 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
604 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
605 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
606 status);
607moo_try_cleanup:
608 return status;
609}
610
611/*----------------------------------------------------------------------------*/
623/*----------------------------------------------------------------------------*/
624cpl_error_code
625moo_qc_set_residy_sd(cpl_propertylist *plist, double val)
626{
627 const char *key = MOONS_QC_RESIDY_SD;
628 const char *comment = MOONS_QC_RESIDY_SD_C;
629
630 cpl_error_code status = CPL_ERROR_NONE;
631
632 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
633 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
634 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
635 status);
636moo_try_cleanup:
637 return status;
638}
639/*----------------------------------------------------------------------------*/
651/*----------------------------------------------------------------------------*/
652cpl_error_code
653moo_qc_set_residy_avg(cpl_propertylist *plist, double val)
654{
655 const char *key = MOONS_QC_RESIDY_AVG;
656 const char *comment = MOONS_QC_RESIDY_AVG_C;
657
658 cpl_error_code status = CPL_ERROR_NONE;
659
660 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
661 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
662 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
663 status);
664moo_try_cleanup:
665 return status;
666}
667
668/*----------------------------------------------------------------------------*/
680/*----------------------------------------------------------------------------*/
681cpl_error_code
682moo_qc_set_widthy_med(cpl_propertylist *plist, double val)
683{
684 const char *key = MOONS_QC_WIDTHY_MED;
685 const char *comment = MOONS_QC_WIDTHY_MED_C;
686
687 cpl_error_code status = CPL_ERROR_NONE;
688
689 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
690 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
691 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
692 status);
693moo_try_cleanup:
694 return status;
695}
696
697/*----------------------------------------------------------------------------*/
709/*----------------------------------------------------------------------------*/
710cpl_error_code
711moo_qc_set_widthy_sd(cpl_propertylist *plist, double val)
712{
713 const char *key = MOONS_QC_WIDTHY_SD;
714 const char *comment = MOONS_QC_WIDTHY_SD_C;
715
716 cpl_error_code status = CPL_ERROR_NONE;
717
718 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
719 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
720 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
721 status);
722moo_try_cleanup:
723 return status;
724}
725/*----------------------------------------------------------------------------*/
737/*----------------------------------------------------------------------------*/
738cpl_error_code
739moo_qc_set_widthy_avg(cpl_propertylist *plist, double val)
740{
741 const char *key = MOONS_QC_WIDTHY_AVG;
742 const char *comment = MOONS_QC_WIDTHY_AVG_C;
743
744 cpl_error_code status = CPL_ERROR_NONE;
745
746 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
747 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
748 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
749 status);
750moo_try_cleanup:
751 return status;
752}
753
754/*----------------------------------------------------------------------------*/
766/*----------------------------------------------------------------------------*/
767cpl_error_code
768moo_qc_set_shifty_pts_med(cpl_propertylist *plist, double val)
769{
770 const char *key = MOONS_QC_SHIFTY_PTS_MED;
771 const char *comment = MOONS_QC_SHIFTY_PTS_MED_C;
772
773 cpl_error_code status = CPL_ERROR_NONE;
774
775 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
776 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
777 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
778 status);
779moo_try_cleanup:
780 return status;
781}
782
783/*----------------------------------------------------------------------------*/
795/*----------------------------------------------------------------------------*/
796cpl_error_code
797moo_qc_set_shifty_pts_avg(cpl_propertylist *plist, double val)
798{
799 const char *key = MOONS_QC_SHIFTY_PTS_AVG;
800 const char *comment = MOONS_QC_SHIFTY_PTS_AVG_C;
801
802 cpl_error_code status = CPL_ERROR_NONE;
803
804 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
805 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
806 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
807 status);
808moo_try_cleanup:
809 return status;
810}
811
812/*----------------------------------------------------------------------------*/
824/*----------------------------------------------------------------------------*/
825cpl_error_code
826moo_qc_set_shifty_pts_sd(cpl_propertylist *plist, double val)
827{
828 const char *key = MOONS_QC_SHIFTY_PTS_SD;
829 const char *comment = MOONS_QC_SHIFTY_PTS_SD_C;
830
831 cpl_error_code status = CPL_ERROR_NONE;
832
833 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
834 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
835 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
836 status);
837moo_try_cleanup:
838 return status;
839}
840
841/*----------------------------------------------------------------------------*/
853/*----------------------------------------------------------------------------*/
854cpl_error_code
855moo_qc_set_shifty_fit_med(cpl_propertylist *plist, double val)
856{
857 const char *key = MOONS_QC_SHIFTY_FIT_MED;
858 const char *comment = MOONS_QC_SHIFTY_FIT_MED_C;
859
860 cpl_error_code status = CPL_ERROR_NONE;
861
862 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
863 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
864 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
865 status);
866moo_try_cleanup:
867 return status;
868}
869
870/*----------------------------------------------------------------------------*/
882/*----------------------------------------------------------------------------*/
883cpl_error_code
884moo_qc_set_shifty_fit_avg(cpl_propertylist *plist, double val)
885{
886 const char *key = MOONS_QC_SHIFTY_FIT_AVG;
887 const char *comment = MOONS_QC_SHIFTY_FIT_AVG_C;
888
889 cpl_error_code status = CPL_ERROR_NONE;
890
891 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
892 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
893 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
894 status);
895moo_try_cleanup:
896 return status;
897}
898
899/*----------------------------------------------------------------------------*/
911/*----------------------------------------------------------------------------*/
912cpl_error_code
913moo_qc_set_shifty_fit_sd(cpl_propertylist *plist, double val)
914{
915 const char *key = MOONS_QC_SHIFTY_FIT_SD;
916 const char *comment = MOONS_QC_SHIFTY_FIT_SD_C;
917
918 cpl_error_code status = CPL_ERROR_NONE;
919
920 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
921 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
922 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
923 status);
924moo_try_cleanup:
925 return status;
926}
927
928/*----------------------------------------------------------------------------*/
940/*----------------------------------------------------------------------------*/
941cpl_error_code
942moo_qc_set_fit_deg(cpl_propertylist *plist, int val)
943{
944 const char *key = MOONS_QC_FIT_DEG;
945 const char *comment = MOONS_QC_FIT_DEG_C;
946
947 cpl_error_code status = CPL_ERROR_NONE;
948
949 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
950 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
951 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
952 status);
953moo_try_cleanup:
954 return status;
955}
956
957/*----------------------------------------------------------------------------*/
969/*----------------------------------------------------------------------------*/
970cpl_error_code
971moo_qc_set_noutlier_pts(cpl_propertylist *plist, int val)
972{
973 const char *key = MOONS_QC_NOUTLIER_PTS;
974 const char *comment = MOONS_QC_NOUTLIER_PTS_C;
975
976 cpl_error_code status = CPL_ERROR_NONE;
977
978 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
979 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
980 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
981 status);
982moo_try_cleanup:
983 return status;
984}
985
986/*----------------------------------------------------------------------------*/
998/*----------------------------------------------------------------------------*/
999cpl_error_code
1000moo_qc_set_noutlier_wid(cpl_propertylist *plist, int val)
1001{
1002 const char *key = MOONS_QC_NOUTLIER_WID;
1003 const char *comment = MOONS_QC_NOUTLIER_WID_C;
1004
1005 cpl_error_code status = CPL_ERROR_NONE;
1006
1007 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1008 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1009 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1010 status);
1011moo_try_cleanup:
1012 return status;
1013}
1014
1015/*----------------------------------------------------------------------------*/
1027/*----------------------------------------------------------------------------*/
1028cpl_error_code
1029moo_qc_set_nbadprofile(cpl_propertylist *plist, int val)
1030{
1031 const char *key = MOONS_QC_NBADPROFILE;
1032 const char *comment = MOONS_QC_NBADPROFILE_C;
1033
1034 cpl_error_code status = CPL_ERROR_NONE;
1035
1036 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1037 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1038 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1039 status);
1040moo_try_cleanup:
1041 return status;
1042}
1043
1044/*----------------------------------------------------------------------------*/
1056/*----------------------------------------------------------------------------*/
1057cpl_error_code
1058moo_qc_set_nbadpix(cpl_propertylist *plist, int val)
1059{
1060 const char *key = MOONS_QC_NBADPIX;
1061 const char *comment = MOONS_QC_NBADPIX_C;
1062
1063 cpl_error_code status = CPL_ERROR_NONE;
1064
1065 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1066 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1067 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1068 status);
1069moo_try_cleanup:
1070 return status;
1071}
1072
1073/*----------------------------------------------------------------------------*/
1085/*----------------------------------------------------------------------------*/
1086cpl_error_code
1087moo_qc_set_nmissingfib(cpl_propertylist *plist, int val)
1088{
1089 const char *key = MOONS_QC_NMISSINGFIB;
1090 const char *comment = MOONS_QC_NMISSINGFIB_C;
1091
1092 cpl_error_code status = CPL_ERROR_NONE;
1093
1094 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1095 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1096 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1097 status);
1098moo_try_cleanup:
1099 return status;
1100}
1101
1102/*----------------------------------------------------------------------------*/
1116/*----------------------------------------------------------------------------*/
1117cpl_error_code
1118moo_qc_set_missingfib(cpl_propertylist *plist, int num, const char *val)
1119{
1120 cpl_error_code status = CPL_ERROR_NONE;
1121
1122 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1123
1124 char *key = cpl_sprintf(MOONS_QC_MISSINGFIB, num);
1125
1126 if (key != NULL) {
1127 moo_ensure_status(cpl_propertylist_append_string(plist, key, val),
1128 status);
1129 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
1130 MOONS_QC_MISSINGFIB_C),
1131 status);
1132 }
1133 else {
1134 status = cpl_error_get_code();
1135 }
1136moo_try_cleanup:
1137 if (key != NULL) {
1138 cpl_free(key);
1139 }
1140 return status;
1141}
1142
1143/*----------------------------------------------------------------------------*/
1155/*----------------------------------------------------------------------------*/
1156cpl_error_code
1157moo_qc_set_p2p_min(cpl_propertylist *plist, double val)
1158{
1159 const char *key = MOONS_QC_P2P_MIN;
1160 const char *comment = MOONS_QC_P2P_MIN_C;
1161
1162 cpl_error_code status = CPL_ERROR_NONE;
1163
1164 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1165 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1166 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1167 status);
1168moo_try_cleanup:
1169 return status;
1170}
1171
1172/*----------------------------------------------------------------------------*/
1184/*----------------------------------------------------------------------------*/
1185cpl_error_code
1186moo_qc_set_p2p_max(cpl_propertylist *plist, double val)
1187{
1188 const char *key = MOONS_QC_P2P_MAX;
1189 const char *comment = MOONS_QC_P2P_MAX_C;
1190
1191 cpl_error_code status = CPL_ERROR_NONE;
1192
1193 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1194 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1195 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1196 status);
1197moo_try_cleanup:
1198 return status;
1199}
1200
1201/*----------------------------------------------------------------------------*/
1213/*----------------------------------------------------------------------------*/
1214cpl_error_code
1215moo_qc_set_p2p_avg(cpl_propertylist *plist, double val)
1216{
1217 const char *key = MOONS_QC_P2P_AVG;
1218 const char *comment = MOONS_QC_P2P_AVG_C;
1219
1220 cpl_error_code status = CPL_ERROR_NONE;
1221
1222 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1223 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1224 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1225 status);
1226moo_try_cleanup:
1227 return status;
1228}
1229
1230/*----------------------------------------------------------------------------*/
1242/*----------------------------------------------------------------------------*/
1243cpl_error_code
1244moo_qc_set_p2p_med(cpl_propertylist *plist, double val)
1245{
1246 const char *key = MOONS_QC_P2P_MED;
1247 const char *comment = MOONS_QC_P2P_MED_C;
1248
1249 cpl_error_code status = CPL_ERROR_NONE;
1250
1251 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1252 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1253 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1254 status);
1255moo_try_cleanup:
1256 return status;
1257}
1258
1259/*----------------------------------------------------------------------------*/
1271/*----------------------------------------------------------------------------*/
1272cpl_error_code
1273moo_qc_set_p2p_mad(cpl_propertylist *plist, double val)
1274{
1275 const char *key = MOONS_QC_P2P_MAD;
1276 const char *comment = MOONS_QC_P2P_MAD_C;
1277
1278 cpl_error_code status = CPL_ERROR_NONE;
1279
1280 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1281 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1282 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1283 status);
1284moo_try_cleanup:
1285 return status;
1286}
1287/*----------------------------------------------------------------------------*/
1299/*----------------------------------------------------------------------------*/
1300cpl_error_code
1301moo_qc_set_p2p_rms(cpl_propertylist *plist, double val)
1302{
1303 const char *key = MOONS_QC_P2P_RMS;
1304 const char *comment = MOONS_QC_P2P_RMS_C;
1305
1306 cpl_error_code status = CPL_ERROR_NONE;
1307
1308 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1309 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1310 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1311 status);
1312moo_try_cleanup:
1313 return status;
1314}
1315/*----------------------------------------------------------------------------*/
1327/*----------------------------------------------------------------------------*/
1328cpl_error_code
1329moo_qc_set_mflat_sn_min(cpl_propertylist *plist, double val)
1330{
1331 const char *key = MOONS_QC_MFLAT_SN_MIN;
1332 const char *comment = MOONS_QC_MFLAT_SN_MIN_C;
1333
1334 cpl_error_code status = CPL_ERROR_NONE;
1335
1336 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1337 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1338 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1339 status);
1340moo_try_cleanup:
1341 return status;
1342}
1343
1344/*----------------------------------------------------------------------------*/
1356/*----------------------------------------------------------------------------*/
1357cpl_error_code
1358moo_qc_set_mflat_sn_max(cpl_propertylist *plist, double val)
1359{
1360 const char *key = MOONS_QC_MFLAT_SN_MAX;
1361 const char *comment = MOONS_QC_MFLAT_SN_MAX_C;
1362
1363 cpl_error_code status = CPL_ERROR_NONE;
1364
1365 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1366 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1367 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1368 status);
1369moo_try_cleanup:
1370 return status;
1371}
1372
1373/*----------------------------------------------------------------------------*/
1385/*----------------------------------------------------------------------------*/
1386cpl_error_code
1387moo_qc_set_mflat_sn_med(cpl_propertylist *plist, double val)
1388{
1389 const char *key = MOONS_QC_MFLAT_SN_MED;
1390 const char *comment = MOONS_QC_MFLAT_SN_MED_C;
1391
1392 cpl_error_code status = CPL_ERROR_NONE;
1393
1394 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1395 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1396 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1397 status);
1398moo_try_cleanup:
1399 return status;
1400}
1401
1402/*----------------------------------------------------------------------------*/
1414/*----------------------------------------------------------------------------*/
1415cpl_error_code
1416moo_qc_set_wave_min(cpl_propertylist *plist, double val)
1417{
1418 const char *key = MOONS_QC_WAVE_MIN;
1419 const char *comment = MOONS_QC_WAVE_MIN_C;
1420
1421 cpl_error_code status = CPL_ERROR_NONE;
1422
1423 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1424 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1425 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1426 status);
1427moo_try_cleanup:
1428 return status;
1429}
1430
1431/*----------------------------------------------------------------------------*/
1443/*----------------------------------------------------------------------------*/
1444cpl_error_code
1445moo_qc_set_wave_max(cpl_propertylist *plist, double val)
1446{
1447 const char *key = MOONS_QC_WAVE_MAX;
1448 const char *comment = MOONS_QC_WAVE_MAX_C;
1449
1450 cpl_error_code status = CPL_ERROR_NONE;
1451
1452 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1453 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1454 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1455 status);
1456moo_try_cleanup:
1457 return status;
1458}
1459
1460/*----------------------------------------------------------------------------*/
1472/*----------------------------------------------------------------------------*/
1473cpl_error_code
1474moo_qc_set_qc_detect_noisemult(cpl_propertylist *plist, double val)
1475{
1476 const char *key = MOONS_QC_DETECT_NOISEMULT;
1477 const char *comment = MOONS_QC_DETECT_NOISEMULT_C;
1478
1479 cpl_error_code status = CPL_ERROR_NONE;
1480
1481 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1482 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1483 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1484 status);
1485moo_try_cleanup:
1486 return status;
1487}
1488
1489/*----------------------------------------------------------------------------*/
1501/*----------------------------------------------------------------------------*/
1502cpl_error_code
1503moo_qc_set_mflat_min(cpl_propertylist *plist, double val)
1504{
1505 const char *key = MOONS_QC_MFLAT_MIN;
1506 const char *comment = MOONS_QC_MFLAT_MIN_C;
1507
1508 cpl_error_code status = CPL_ERROR_NONE;
1509
1510 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1511 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1512 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1513 status);
1514moo_try_cleanup:
1515 return status;
1516}
1517
1518/*----------------------------------------------------------------------------*/
1530/*----------------------------------------------------------------------------*/
1531cpl_error_code
1532moo_qc_set_mflat_max(cpl_propertylist *plist, double val)
1533{
1534 const char *key = MOONS_QC_MFLAT_MAX;
1535 const char *comment = MOONS_QC_MFLAT_MAX_C;
1536
1537 cpl_error_code status = CPL_ERROR_NONE;
1538
1539 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1540 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1541 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1542 status);
1543moo_try_cleanup:
1544 return status;
1545}
1546
1547/*----------------------------------------------------------------------------*/
1559/*----------------------------------------------------------------------------*/
1560cpl_error_code
1561moo_qc_set_mflat_avg(cpl_propertylist *plist, double val)
1562{
1563 const char *key = MOONS_QC_MFLAT_AVG;
1564 const char *comment = MOONS_QC_MFLAT_AVG_C;
1565
1566 cpl_error_code status = CPL_ERROR_NONE;
1567
1568 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1569 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1570 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1571 status);
1572moo_try_cleanup:
1573 return status;
1574}
1575
1576/*----------------------------------------------------------------------------*/
1588/*----------------------------------------------------------------------------*/
1589cpl_error_code
1590moo_qc_set_mflat_med(cpl_propertylist *plist, double val)
1591{
1592 const char *key = MOONS_QC_MFLAT_MED;
1593 const char *comment = MOONS_QC_MFLAT_MED_C;
1594
1595 cpl_error_code status = CPL_ERROR_NONE;
1596
1597 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1598 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1599 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1600 status);
1601moo_try_cleanup:
1602 return status;
1603}
1604
1605/*----------------------------------------------------------------------------*/
1617/*----------------------------------------------------------------------------*/
1618cpl_error_code
1619moo_qc_set_mflat_rms(cpl_propertylist *plist, double val)
1620{
1621 const char *key = MOONS_QC_MFLAT_RMS;
1622 const char *comment = MOONS_QC_MFLAT_RMS_C;
1623
1624 cpl_error_code status = CPL_ERROR_NONE;
1625
1626 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1627 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
1628 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1629 status);
1630moo_try_cleanup:
1631 return status;
1632}
1633
1634/*----------------------------------------------------------------------------*/
1648/*----------------------------------------------------------------------------*/
1649cpl_error_code
1650moo_qc_set_fibtrans_ref(cpl_propertylist *plist, int ntas, int val)
1651{
1652 cpl_error_code status = CPL_ERROR_NONE;
1653
1654 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1655
1656 char *comment = NULL;
1657 char *key = cpl_sprintf(MOONS_QC_FIBTRANS_REF, ntas);
1658
1659 if (key != NULL) {
1660 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1661 comment = cpl_sprintf(MOONS_QC_FIBTRANS_REF_C, ntas);
1662 if (comment != NULL) {
1663 moo_ensure_status(cpl_propertylist_set_comment(
1664 plist, key, MOONS_QC_FIBTRANS_REF_C),
1665 status);
1666 }
1667 else {
1668 status = cpl_error_get_code();
1669 }
1670 }
1671 else {
1672 status = cpl_error_get_code();
1673 }
1674moo_try_cleanup:
1675 if (key != NULL) {
1676 cpl_free(key);
1677 }
1678 if (comment != NULL) {
1679 cpl_free(comment);
1680 }
1681 return status;
1682}
1683
1684/*----------------------------------------------------------------------------*/
1698/*----------------------------------------------------------------------------*/
1699cpl_error_code
1700moo_qc_set_fibtrans_min(cpl_propertylist *plist,
1701 moo_detector_type type,
1702 double val)
1703{
1704 cpl_error_code status = CPL_ERROR_NONE;
1705
1706 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1707
1708 char *key = cpl_sprintf(MOONS_QC_FIBTRANS_MIN, moo_detector_get_name(type));
1709
1710 if (key != NULL) {
1711 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
1712 status);
1713 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
1714 MOONS_QC_FIBTRANS_MIN_C),
1715 status);
1716 }
1717 else {
1718 status = cpl_error_get_code();
1719 }
1720moo_try_cleanup:
1721 if (key != NULL) {
1722 cpl_free(key);
1723 }
1724 return status;
1725}
1726
1727/*----------------------------------------------------------------------------*/
1741/*----------------------------------------------------------------------------*/
1742cpl_error_code
1743moo_qc_set_fibtrans_max(cpl_propertylist *plist,
1744 moo_detector_type type,
1745 double val)
1746{
1747 cpl_error_code status = CPL_ERROR_NONE;
1748
1749 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1750
1751 char *key = cpl_sprintf(MOONS_QC_FIBTRANS_MAX, moo_detector_get_name(type));
1752
1753 if (key != NULL) {
1754 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
1755 status);
1756 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
1757 MOONS_QC_FIBTRANS_MAX_C),
1758 status);
1759 }
1760 else {
1761 status = cpl_error_get_code();
1762 }
1763moo_try_cleanup:
1764 if (key != NULL) {
1765 cpl_free(key);
1766 }
1767 return status;
1768}
1769
1770/*----------------------------------------------------------------------------*/
1784/*----------------------------------------------------------------------------*/
1785cpl_error_code
1786moo_qc_set_fibtrans_med(cpl_propertylist *plist,
1787 moo_detector_type type,
1788 double val)
1789{
1790 cpl_error_code status = CPL_ERROR_NONE;
1791
1792 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1793
1794 char *key = cpl_sprintf(MOONS_QC_FIBTRANS_MED, moo_detector_get_name(type));
1795
1796 if (key != NULL) {
1797 moo_ensure_status(cpl_propertylist_append_double(plist, key, val),
1798 status);
1799 moo_ensure_status(cpl_propertylist_set_comment(plist, key,
1800 MOONS_QC_FIBTRANS_MED_C),
1801 status);
1802 }
1803 else {
1804 status = cpl_error_get_code();
1805 }
1806moo_try_cleanup:
1807 if (key != NULL) {
1808 cpl_free(key);
1809 }
1810 return status;
1811}
1812/*----------------------------------------------------------------------------*/
1824/*----------------------------------------------------------------------------*/
1825cpl_error_code
1826moo_qc_set_wavecal_catline(cpl_propertylist *plist, int val)
1827{
1828 const char *key = MOONS_QC_WAVECAL_CATLINE;
1829 const char *comment = MOONS_QC_WAVECAL_CATLINE_C;
1830
1831 cpl_error_code status = CPL_ERROR_NONE;
1832
1833 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1834 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1835 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1836 status);
1837moo_try_cleanup:
1838 return status;
1839}
1840
1841/*----------------------------------------------------------------------------*/
1853/*----------------------------------------------------------------------------*/
1854cpl_error_code
1855moo_qc_set_wavecal_detectline(cpl_propertylist *plist, int val)
1856{
1857 const char *key = MOONS_QC_WAVECAL_DETECTLINE;
1858 const char *comment = MOONS_QC_WAVECAL_DETECTLINE_C;
1859
1860 cpl_error_code status = CPL_ERROR_NONE;
1861
1862 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1863 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1864 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1865 status);
1866moo_try_cleanup:
1867 return status;
1868}
1869
1870/*----------------------------------------------------------------------------*/
1882/*----------------------------------------------------------------------------*/
1883cpl_error_code
1884moo_qc_set_wavecal_failedfit(cpl_propertylist *plist, int val)
1885{
1886 const char *key = MOONS_QC_WAVECAL_FAILEDFIT;
1887 const char *comment = MOONS_QC_WAVECAL_FAILEDFIT_C;
1888
1889 cpl_error_code status = CPL_ERROR_NONE;
1890
1891 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1892 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1893 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1894 status);
1895moo_try_cleanup:
1896 return status;
1897}
1898
1899/*----------------------------------------------------------------------------*/
1911/*----------------------------------------------------------------------------*/
1912cpl_error_code
1913moo_qc_set_wavecal_fitline(cpl_propertylist *plist, int val)
1914{
1915 const char *key = MOONS_QC_WAVECAL_FITLINE;
1916 const char *comment = MOONS_QC_WAVECAL_FITLINE_C;
1917
1918 cpl_error_code status = CPL_ERROR_NONE;
1919
1920 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1921 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1922 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1923 status);
1924moo_try_cleanup:
1925 return status;
1926}
1927
1928/*----------------------------------------------------------------------------*/
1940/*----------------------------------------------------------------------------*/
1941cpl_error_code
1942moo_qc_set_wavecal_matchline(cpl_propertylist *plist, int val)
1943{
1944 const char *key = MOONS_QC_WAVECAL_MATCHLINE;
1945 const char *comment = MOONS_QC_WAVECAL_MATCHLINE_C;
1946
1947 cpl_error_code status = CPL_ERROR_NONE;
1948
1949 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1950 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1951 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1952 status);
1953moo_try_cleanup:
1954 return status;
1955}
1956
1957/*----------------------------------------------------------------------------*/
1969/*----------------------------------------------------------------------------*/
1970cpl_error_code
1971moo_qc_set_wavecal_clipline(cpl_propertylist *plist, int val)
1972{
1973 const char *key = MOONS_QC_WAVECAL_CLIPLINE;
1974 const char *comment = MOONS_QC_WAVECAL_CLIPLINE_C;
1975
1976 cpl_error_code status = CPL_ERROR_NONE;
1977
1978 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
1979 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
1980 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
1981 status);
1982moo_try_cleanup:
1983 return status;
1984}
1985
1986/*----------------------------------------------------------------------------*/
1998/*----------------------------------------------------------------------------*/
1999cpl_error_code
2000moo_qc_set_wavecal_monotonous_solution(cpl_propertylist *plist, int val)
2001{
2002 const char *key = MOONS_QC_WAVECAL_MONOTONOUS_SOLUTION;
2003 const char *comment = MOONS_QC_WAVECAL_MONOTONOUS_SOLUTION_C;
2004
2005 cpl_error_code status = CPL_ERROR_NONE;
2006
2007 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2008
2009 moo_ensure_status(cpl_propertylist_append_bool(plist, key, val), status);
2010 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2011 status);
2012moo_try_cleanup:
2013 return status;
2014}
2015
2016/*----------------------------------------------------------------------------*/
2028/*----------------------------------------------------------------------------*/
2029cpl_error_code
2030moo_qc_set_wavecal_validfibre(cpl_propertylist *plist, int val)
2031{
2032 const char *key = MOONS_QC_WAVECAL_VALIDFIBRE;
2033 const char *comment = MOONS_QC_WAVECAL_VALIDFIBRE_C;
2034
2035 cpl_error_code status = CPL_ERROR_NONE;
2036
2037 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2038 moo_ensure_status(cpl_propertylist_append_int(plist, key, val), status);
2039 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2040 status);
2041
2042moo_try_cleanup:
2043 return status;
2044}
2045
2046/*----------------------------------------------------------------------------*/
2059/*----------------------------------------------------------------------------*/
2060cpl_error_code
2061moo_qc_set_wavecal_disp_min(cpl_propertylist *plist, double val)
2062{
2063 const char *key = MOONS_QC_WAVECAL_DISP_MIN;
2064 const char *comment = MOONS_QC_WAVECAL_DISP_MIN_C;
2065 cpl_error_code status = CPL_ERROR_NONE;
2066
2067 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2068
2069 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
2070 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2071 status);
2072
2073moo_try_cleanup:
2074 return status;
2075}
2076
2077/*----------------------------------------------------------------------------*/
2090/*----------------------------------------------------------------------------*/
2091cpl_error_code
2092moo_qc_set_wavecal_disp_max(cpl_propertylist *plist, double val)
2093{
2094 const char *key = MOONS_QC_WAVECAL_DISP_MAX;
2095 const char *comment = MOONS_QC_WAVECAL_DISP_MAX_C;
2096 cpl_error_code status = CPL_ERROR_NONE;
2097
2098 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2099
2100 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
2101 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2102 status);
2103
2104moo_try_cleanup:
2105 return status;
2106}
2107
2108/*----------------------------------------------------------------------------*/
2121/*----------------------------------------------------------------------------*/
2122cpl_error_code
2123moo_qc_set_wavecal_resol_med(cpl_propertylist *plist, double val)
2124{
2125 const char *key = MOONS_QC_WAVECAL_RESOL_MED;
2126 const char *comment = MOONS_QC_WAVECAL_RESOL_MED_C;
2127 cpl_error_code status = CPL_ERROR_NONE;
2128
2129 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2130
2131 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
2132 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2133 status);
2134
2135moo_try_cleanup:
2136 return status;
2137}
2138
2139/*----------------------------------------------------------------------------*/
2152/*----------------------------------------------------------------------------*/
2153cpl_error_code
2154moo_qc_set_wavecal_residwave_med(cpl_propertylist *plist, double val)
2155{
2156 const char *key = MOONS_QC_WAVECAL_RESIDWAVE_MED;
2157 const char *comment = MOONS_QC_WAVECAL_RESIDWAVE_MED_C;
2158 cpl_error_code status = CPL_ERROR_NONE;
2159
2160 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2161
2162 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
2163 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2164 status);
2165
2166moo_try_cleanup:
2167 return status;
2168}
2169
2170/*----------------------------------------------------------------------------*/
2183/*----------------------------------------------------------------------------*/
2184cpl_error_code
2185moo_qc_set_wavecal_residwave_std(cpl_propertylist *plist, double val)
2186{
2187 const char *key = MOONS_QC_WAVECAL_RESIDWAVE_STD;
2188 const char *comment = MOONS_QC_WAVECAL_RESIDWAVE_STD_C;
2189 cpl_error_code status = CPL_ERROR_NONE;
2190
2191 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2192
2193 moo_ensure_status(cpl_propertylist_append_double(plist, key, val), status);
2194 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2195 status);
2196
2197moo_try_cleanup:
2198 return status;
2199}
2200/******************************************************************************/
2201
2202/*----------------------------------------------------------------------------*/
2215/*----------------------------------------------------------------------------*/
2216int
2217moo_qc_get_ncom(cpl_propertylist *plist)
2218{
2219 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2220 return cpl_propertylist_get_int(plist, MOONS_QC_NCOM);
2221}
2222
2223/*----------------------------------------------------------------------------*/
2236/*----------------------------------------------------------------------------*/
2237cpl_error_code
2238moo_qc_set_snr_range(cpl_propertylist *plist, const char *val)
2239{
2240 cpl_error_code status = CPL_ERROR_NONE;
2241
2242 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2243
2244 if (cpl_propertylist_has(plist, MOONS_QC_SNR_RANGE)) {
2245 moo_ensure_status(cpl_propertylist_set_string(plist, MOONS_QC_SNR_RANGE,
2246 val),
2247 status);
2248 }
2249 else {
2250 moo_ensure_status(cpl_propertylist_append_string(plist,
2251 MOONS_QC_SNR_RANGE,
2252 val),
2253 status);
2254 moo_ensure_status(cpl_propertylist_set_comment(plist,
2255 MOONS_QC_SNR_RANGE,
2256 MOONS_QC_SNR_RANGE_C),
2257 status);
2258 }
2259
2260
2261moo_try_cleanup:
2262 return status;
2263}
2264
2265/*----------------------------------------------------------------------------*/
2278/*----------------------------------------------------------------------------*/
2279cpl_error_code
2280moo_qc_set_frame_raw1(cpl_propertylist *plist, const char *val)
2281{
2282 const char *value = NULL;
2283 cpl_error_code status = CPL_ERROR_NONE;
2284
2285 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2286
2287 char *name = strrchr(val, '/');
2288 if (name != NULL) {
2289 value = name + 1;
2290 }
2291 else {
2292 value = val;
2293 }
2294 if (cpl_propertylist_has(plist, MOONS_QC_FRAME_RAW1)) {
2295 moo_ensure_status(cpl_propertylist_set_string(plist,
2296 MOONS_QC_FRAME_RAW1,
2297 value),
2298 status);
2299 }
2300 else {
2301 moo_ensure_status(cpl_propertylist_append_string(plist,
2302 MOONS_QC_FRAME_RAW1,
2303 value),
2304 status);
2305 moo_ensure_status(cpl_propertylist_set_comment(plist,
2306 MOONS_QC_FRAME_RAW1,
2307 MOONS_QC_FRAME_RAW1_C),
2308 status);
2309 }
2310
2311
2312moo_try_cleanup:
2313 return status;
2314}
2315
2316/*----------------------------------------------------------------------------*/
2329/*----------------------------------------------------------------------------*/
2330cpl_error_code
2331moo_qc_set_frame_raw2(cpl_propertylist *plist, const char *val)
2332{
2333 const char *value = NULL;
2334 cpl_error_code status = CPL_ERROR_NONE;
2335
2336 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2337
2338 char *name = strrchr(val, '/');
2339 if (name != NULL) {
2340 value = name + 1;
2341 }
2342 else {
2343 value = val;
2344 }
2345 if (cpl_propertylist_has(plist, MOONS_QC_FRAME_RAW2)) {
2346 moo_ensure_status(cpl_propertylist_set_string(plist,
2347 MOONS_QC_FRAME_RAW2,
2348 value),
2349 status);
2350 }
2351 else {
2352 moo_ensure_status(cpl_propertylist_append_string(plist,
2353 MOONS_QC_FRAME_RAW2,
2354 value),
2355 status);
2356 moo_ensure_status(cpl_propertylist_set_comment(plist,
2357 MOONS_QC_FRAME_RAW2,
2358 MOONS_QC_FRAME_RAW2_C),
2359 status);
2360 }
2361
2362
2363moo_try_cleanup:
2364 return status;
2365}
2366/*----------------------------------------------------------------------------*/
2379/*----------------------------------------------------------------------------*/
2380cpl_error_code
2381moo_qc_set_is_linearcor(cpl_propertylist *plist, cpl_boolean val)
2382{
2383 const char *key = MOONS_QC_IS_LINEARCOR;
2384 const char *comment = MOONS_QC_IS_LINEARCOR_C;
2385 cpl_error_code status = CPL_ERROR_NONE;
2386
2387 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2388 if (cpl_propertylist_has(plist, key)) {
2389 moo_ensure_status(cpl_propertylist_set_bool(plist, key, val), status);
2390 }
2391 else {
2392 moo_ensure_status(cpl_propertylist_append_bool(plist, key, val),
2393 status);
2394 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2395 status);
2396 }
2397moo_try_cleanup:
2398 return status;
2399}
2400
2401/*----------------------------------------------------------------------------*/
2414/*----------------------------------------------------------------------------*/
2415cpl_error_code
2416moo_qc_set_is_p2pcor(cpl_propertylist *plist, cpl_boolean val)
2417{
2418 const char *key = MOONS_QC_IS_P2PCOR;
2419 const char *comment = MOONS_QC_IS_P2PCOR_C;
2420 cpl_error_code status = CPL_ERROR_NONE;
2421
2422 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2423 if (cpl_propertylist_has(plist, key)) {
2424 moo_ensure_status(cpl_propertylist_set_bool(plist, key, val), status);
2425 }
2426 else {
2427 moo_ensure_status(cpl_propertylist_append_bool(plist, key, val),
2428 status);
2429 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2430 status);
2431 }
2432moo_try_cleanup:
2433 return status;
2434}
2435
2436/*----------------------------------------------------------------------------*/
2449/*----------------------------------------------------------------------------*/
2450cpl_error_code
2451moo_qc_set_is_tellcor(cpl_propertylist *plist, cpl_boolean val)
2452{
2453 const char *key = MOONS_QC_IS_TELLCOR;
2454 const char *comment = MOONS_QC_IS_TELLCOR_C;
2455 cpl_error_code status = CPL_ERROR_NONE;
2456
2457 cpl_ensure_code(plist != NULL, CPL_ERROR_NULL_INPUT);
2458 if (cpl_propertylist_has(plist, key)) {
2459 moo_ensure_status(cpl_propertylist_set_bool(plist, key, val), status);
2460 }
2461 else {
2462 moo_ensure_status(cpl_propertylist_append_bool(plist, key, val),
2463 status);
2464 moo_ensure_status(cpl_propertylist_set_comment(plist, key, comment),
2465 status);
2466 }
2467moo_try_cleanup:
2468 return status;
2469}
const char * moo_detector_get_name(moo_detector_type type)
Get the extension name of a detector.
Definition: moo_detector.c:183
enum _moo_detector_type_ moo_detector_type
The type code type.
Definition: moo_detector.h:64
cpl_error_code moo_qc_set_p2p_max(cpl_propertylist *plist, double val)
Set the QC.P2P.MAX value.
Definition: moo_qc.c:1186
cpl_error_code moo_qc_set_mdark_normalise_factor(cpl_propertylist *plist, double val)
Set the QC.MDARK.NORMALISE.FACTOR value.
Definition: moo_qc.c:481
cpl_error_code moo_qc_set_ron_raw(cpl_propertylist *plist, int i, double val)
Set the QC.RON.RAW value.
Definition: moo_qc.c:344
cpl_error_code moo_qc_set_snr_range(cpl_propertylist *plist, const char *val)
Set the QC.SNR.RANGE value.
Definition: moo_qc.c:2238
cpl_error_code moo_qc_set_wavecal_residwave_std(cpl_propertylist *plist, double val)
Set the QC.WAVECAL.RESIDWAVE.STD value.
Definition: moo_qc.c:2185
cpl_error_code moo_qc_set_fibtrans_ref(cpl_propertylist *plist, int ntas, int val)
Set the QC.SPECTRO.FIBTRANS.REF.value.
Definition: moo_qc.c:1650
cpl_error_code moo_qc_set_widthy_sd(cpl_propertylist *plist, double val)
Set the QC.WIDTHY.STD value.
Definition: moo_qc.c:711
cpl_error_code moo_qc_set_p2p_med(cpl_propertylist *plist, double val)
Set the QC.P2P.MED value.
Definition: moo_qc.c:1244
cpl_error_code moo_qc_set_shifty_fit_sd(cpl_propertylist *plist, double val)
Set the QC.SHIFTY.FIT.SD value.
Definition: moo_qc.c:913
cpl_error_code moo_qc_set_wavecal_validfibre(cpl_propertylist *plist, int val)
Set the QC.WAVECAL.VALIDFIBRE value.
Definition: moo_qc.c:2030
cpl_error_code moo_qc_set_wavecal_catline(cpl_propertylist *plist, int val)
Set the QC.WAVECAL.CATLINE value.
Definition: moo_qc.c:1826
cpl_error_code moo_qc_set_wavecal_monotonous_solution(cpl_propertylist *plist, int val)
Set the QC.WAVECAL.MONOTONOUS.SOLUTION value.
Definition: moo_qc.c:2000
cpl_error_code moo_qc_set_wavecal_disp_max(cpl_propertylist *plist, double val)
Set the QC.WAVECAL.DISP.MAX value.
Definition: moo_qc.c:2092
cpl_error_code moo_qc_set_wavecal_matchline(cpl_propertylist *plist, int val)
Set the QC.WAVECAL.MATCHLINE value.
Definition: moo_qc.c:1942
cpl_error_code moo_qc_set_widthy_med(cpl_propertylist *plist, double val)
Set the QC.WIDTHY.MED value.
Definition: moo_qc.c:682
cpl_error_code moo_qc_set_mbias_mad(cpl_propertylist *plist, int i, double val)
Set the QC.MBIAS.MAD value.
Definition: moo_qc.c:303
cpl_error_code moo_qc_set_nbadprofile(cpl_propertylist *plist, int val)
Set the QC.NBADPROFILE value.
Definition: moo_qc.c:1029
cpl_error_code moo_qc_set_noutlier_wid(cpl_propertylist *plist, int val)
Set the QC.NOUTLIER.WID value.
Definition: moo_qc.c:1000
cpl_error_code moo_qc_set_mdark_nhot(cpl_propertylist *plist, int val)
Set the QC.MDARK.NHOT value.
Definition: moo_qc.c:424
cpl_error_code moo_qc_set_p2p_min(cpl_propertylist *plist, double val)
Set the QC.P2P.MIN value.
Definition: moo_qc.c:1157
cpl_error_code moo_qc_set_is_linearcor(cpl_propertylist *plist, cpl_boolean val)
Set the QC.IS.LINEARCOR value.
Definition: moo_qc.c:2381
cpl_error_code moo_qc_set_mflat_max(cpl_propertylist *plist, double val)
Set the QC.MFLAT.MAX value.
Definition: moo_qc.c:1532
cpl_error_code moo_qc_set_fibtrans_med(cpl_propertylist *plist, moo_detector_type type, double val)
Set the QC.FIBTRANS.MED value.
Definition: moo_qc.c:1786
cpl_error_code moo_qc_set_p2p_mad(cpl_propertylist *plist, double val)
Set the QC.P2P.MAD value.
Definition: moo_qc.c:1273
cpl_error_code moo_qc_set_mdark_rms(cpl_propertylist *plist, double val)
Set the QC.MDARK.RMS value.
Definition: moo_qc.c:538
cpl_error_code moo_qc_set_mflat_min(cpl_propertylist *plist, double val)
Set the QC.MFLAT.MIN value.
Definition: moo_qc.c:1503
cpl_error_code moo_qc_set_mflat_sn_max(cpl_propertylist *plist, double val)
Set the QC.MFLAT.SN.MAX value.
Definition: moo_qc.c:1358
cpl_error_code moo_qc_set_wavecal_failedfit(cpl_propertylist *plist, int val)
Set the QC.WAVECAL.FAILEDFIT value.
Definition: moo_qc.c:1884
cpl_error_code moo_qc_set_mflat_sn_min(cpl_propertylist *plist, double val)
Set the QC.MFLAT.SN.MIN value.
Definition: moo_qc.c:1329
cpl_error_code moo_qc_set_ncrh(cpl_propertylist *plist, int val)
Set the QC.NCRH value.
Definition: moo_qc.c:62
cpl_error_code moo_qc_set_residy_med(cpl_propertylist *plist, double val)
Set the QC.RESIDY.MED value.
Definition: moo_qc.c:596
cpl_error_code moo_qc_set_shifty_pts_avg(cpl_propertylist *plist, double val)
Set the QC.SHIFTY.PTS.AVG value.
Definition: moo_qc.c:797
cpl_error_code moo_qc_set_mdark_avg(cpl_propertylist *plist, double val)
Set the QC.MDARK.AVG value.
Definition: moo_qc.c:453
cpl_error_code moo_qc_set_wavecal_clipline(cpl_propertylist *plist, int val)
Set the QC.WAVECAL.CLIPLINE value.
Definition: moo_qc.c:1971
cpl_error_code moo_qc_set_wavecal_residwave_med(cpl_propertylist *plist, double val)
Set the QC.WAVECAL.RESIDWAVE.MED value.
Definition: moo_qc.c:2154
cpl_error_code moo_qc_set_wavecal_disp_min(cpl_propertylist *plist, double val)
Set the QC.WAVECAL.DISP.MIN value.
Definition: moo_qc.c:2061
cpl_error_code moo_qc_set_widthy_avg(cpl_propertylist *plist, double val)
Set the QC.WIDTH.AVG value.
Definition: moo_qc.c:739
cpl_error_code moo_qc_set_ncrh_tot(cpl_propertylist *plist, int val)
Set the QC.NCRH.TOT value.
Definition: moo_qc.c:91
int moo_qc_get_ncom(cpl_propertylist *plist)
Get the QC.NCOM value.
Definition: moo_qc.c:2217
cpl_error_code moo_qc_set_residy_avg(cpl_propertylist *plist, double val)
Set the QC.RESIDY.AVG value.
Definition: moo_qc.c:653
cpl_error_code moo_qc_set_missingfib(cpl_propertylist *plist, int num, const char *val)
Set the QC.MISSINGFIB value.
Definition: moo_qc.c:1118
cpl_error_code moo_qc_set_mbias_med(cpl_propertylist *plist, int i, double val)
Set the QC.MBIAS.MED value.
Definition: moo_qc.c:221
cpl_error_code moo_qc_set_shifty_fit_avg(cpl_propertylist *plist, double val)
Set the QC.SHIFTY.FIT.AVG value.
Definition: moo_qc.c:884
cpl_error_code moo_qc_set_wavecal_resol_med(cpl_propertylist *plist, double val)
Set the QC.WAVECAL.RESOL.MED value.
Definition: moo_qc.c:2123
cpl_error_code moo_qc_set_frame_raw1(cpl_propertylist *plist, const char *val)
Set the QC.FRAME.RAW1 value.
Definition: moo_qc.c:2280
cpl_error_code moo_qc_set_nmissingfib(cpl_propertylist *plist, int val)
Set the QC.NMISSINGFIB value.
Definition: moo_qc.c:1087
cpl_error_code moo_qc_set_wave_min(cpl_propertylist *plist, double val)
Set the QC.WAVE.MIN value.
Definition: moo_qc.c:1416
cpl_error_code moo_qc_set_ncrh_avg(cpl_propertylist *plist, float val)
Set the QC.NCRH value.
Definition: moo_qc.c:120
cpl_error_code moo_qc_set_fibtrans_min(cpl_propertylist *plist, moo_detector_type type, double val)
Set the QC.FIBTRANS.MIN value.
Definition: moo_qc.c:1700
cpl_error_code moo_qc_set_mdark_current(cpl_propertylist *plist, double val)
Set the QC.MEAN.DARK.CURRENT value.
Definition: moo_qc.c:567
cpl_error_code moo_qc_set_ron_master(cpl_propertylist *plist, int i, double val)
Set the QC.RON.MASTER value.
Definition: moo_qc.c:385
cpl_error_code moo_qc_set_mflat_rms(cpl_propertylist *plist, double val)
Set the QC.MFLAT.RMS value.
Definition: moo_qc.c:1619
cpl_error_code moo_qc_set_ncom(cpl_propertylist *plist, int val)
Set the QC.NCOM value.
Definition: moo_qc.c:149
cpl_error_code moo_qc_set_is_p2pcor(cpl_propertylist *plist, cpl_boolean val)
Set the QC.IS.P2PCOR value.
Definition: moo_qc.c:2416
cpl_error_code moo_qc_set_qc_detect_noisemult(cpl_propertylist *plist, double val)
Set the QC.DETECT.NOISEMULT value.
Definition: moo_qc.c:1474
cpl_error_code moo_qc_set_mbias_avg(cpl_propertylist *plist, int i, double val)
Set the QC.MBIAS.AVG value.
Definition: moo_qc.c:180
cpl_error_code moo_qc_set_shifty_pts_sd(cpl_propertylist *plist, double val)
Set the QC.SHIFTY.PTS.SD value.
Definition: moo_qc.c:826
cpl_error_code moo_qc_set_fit_deg(cpl_propertylist *plist, int val)
Set the QC.RESIDY.AVG value.
Definition: moo_qc.c:942
cpl_error_code moo_qc_set_wavecal_detectline(cpl_propertylist *plist, int val)
Set the QC.WAVECAL.DETECTLINE value.
Definition: moo_qc.c:1855
cpl_error_code moo_qc_set_wavecal_fitline(cpl_propertylist *plist, int val)
Set the QC.WAVECAL.FITLINE value.
Definition: moo_qc.c:1913
cpl_error_code moo_qc_set_p2p_avg(cpl_propertylist *plist, double val)
Set the QC.P2P.AVG value.
Definition: moo_qc.c:1215
cpl_error_code moo_qc_set_mflat_sn_med(cpl_propertylist *plist, double val)
Set the QC.MFLAT.SN.MED value.
Definition: moo_qc.c:1387
cpl_error_code moo_qc_set_p2p_rms(cpl_propertylist *plist, double val)
Set the QC.P2P.RMS value.
Definition: moo_qc.c:1301
cpl_error_code moo_qc_set_mflat_med(cpl_propertylist *plist, double val)
Set the QC.MFLAT.MED value.
Definition: moo_qc.c:1590
cpl_error_code moo_qc_set_nbadpix(cpl_propertylist *plist, int val)
Set the QC.NBADPIX value.
Definition: moo_qc.c:1058
cpl_error_code moo_qc_set_frame_raw2(cpl_propertylist *plist, const char *val)
Set the QC.FRAME.RAW2 value.
Definition: moo_qc.c:2331
cpl_error_code moo_qc_set_noutlier_pts(cpl_propertylist *plist, int val)
Set the QC.NOUTLIER.PTS value.
Definition: moo_qc.c:971
cpl_error_code moo_qc_set_mdark_med(cpl_propertylist *plist, double val)
Set the QC.MDARK.MED value.
Definition: moo_qc.c:509
cpl_error_code moo_qc_set_is_tellcor(cpl_propertylist *plist, cpl_boolean val)
Set the QC.IS.TELLCOR value.
Definition: moo_qc.c:2451
cpl_error_code moo_qc_set_fibtrans_max(cpl_propertylist *plist, moo_detector_type type, double val)
Set the QC.FIBTRANS.MAX value.
Definition: moo_qc.c:1743
cpl_error_code moo_qc_set_mbias_rms(cpl_propertylist *plist, int i, double val)
Set the QC.MBIAS.AVG value.
Definition: moo_qc.c:262
cpl_error_code moo_qc_set_shifty_pts_med(cpl_propertylist *plist, double val)
Set the QC.SHIFTY.PTS.MED value.
Definition: moo_qc.c:768
cpl_error_code moo_qc_set_shifty_fit_med(cpl_propertylist *plist, double val)
Set the QC.SHIFTY.FIT.MED value.
Definition: moo_qc.c:855
cpl_error_code moo_qc_set_residy_sd(cpl_propertylist *plist, double val)
Set the QC.RESIDY.STD value.
Definition: moo_qc.c:625
cpl_error_code moo_qc_set_wave_max(cpl_propertylist *plist, double val)
Set the QC.WAVE.MAX value.
Definition: moo_qc.c:1445
cpl_error_code moo_qc_set_mflat_avg(cpl_propertylist *plist, double val)
Set the QC.MFLAT.AVG value.
Definition: moo_qc.c:1561