OB.DAAC Logo
NASA Logo
Ocean Color Science Software

ocssw V2022
Reflective_Cal.h
Go to the documentation of this file.
1 #ifndef REFLECTIVE_CAL_H
2 #define REFLECTIVE_CAL_H
3 
4 /*
5  * UNCOMMENT THE FOLLOWING LINE TO USE THE BAND 5 RADIANCE OFFSET IN THE
6  * CALCULATION OF THE BAND 26 CROSSTALK CORRECTION:
7  */
8 /* #define USE_B5_RAD_OFFSET */
9 
10 #include "L1B_Tables.h" /* contains declarations of look up table varables and
11  Granule.h */
12 #include "Preprocess.h" /* for Preprocess_Data_t definition */
13 
14 /*
15 !C-INC***********************************************************************
16 !Description: Contains external declarations for reflective calculation functions.
17 
18 !Revision History:
19  $Log: Reflective_Cal.h,v $
20  Revision 1.8 2006-10-27 11:01:37-04 ltan
21  Changed for ANSI-C compliance. Correction for the generation of code change log.
22 
23  Revision 01.20 March 26, 2003 Razor Issue #190
24  Added function prototype for Band_26_Crosstalk_Correction to Aqua code
25  (Added previously to Terra code; Razor Issue #182.)
26  Alice Isaacman SAIC GSO (Alice.R.Isaacman.1@gsfc.nasa.gov)
27 
28  Revision 01.10 May 13, 1999
29  Added band 26 section
30  Jim Rogers (rogers@mcst.gsfc.nasa.gov)
31 
32  Revision 01.01 Feb 17, 1999
33  Moved DN_to_DN_star to Preprocess.h as part of moving DN_to_DN_star
34  to Preprocess.c to avoid circular include dependencies.
35  Jim Rogers (rogers@mcst.gsfc.nasa.gov)
36 
37  Revision 01.00 Nov 1998
38  initial development
39  Zhenying Gu (zgu@mcst.gsfc.nasa.gov)
40 
41 !References and Credits:
42  This software is developed by the MODIS Characterization Support
43  Team (MCST) for the National Aeronautics and Space Administration,
44  Goddard Space Flight Center, under contract NAS5-32373.
45 
46  HDF portions developed at the National Center for Supercomputing
47  Applications at the University of Illinois at Urbana-Champaign.
48 
49 !Design Notes:
50 
51 !END********************************************************************
52 */
53 
54 /************************* Begin Band 26 Section **************************/
55 #ifdef WRITE_BAND_26_SDS
56 
57 /* Use the external variable Reflective_Cal_Band_Flag to signal to
58  * Reflective_Cal whether we should calculate only band 26 or all
59  * reflective bands. The macros ALL_REFLECTIVE_BANDS and
60  * REFLECTIVE_BAND_26_ONLY are the allowable values for
61  * Reflective_Cal_Band_Flag.
62  */
63 #define ALL_REFLECTIVE_BANDS 1
64 #define REFLECTIVE_BAND_26_ONLY 2
65 extern int32 Reflective_Cal_Band_Flag;
66 extern PGSt_SMF_status Copy_Band_26_Data (L1B_Scan_t *L1B_Scan);
67 
68 #endif /* WRITE_BAND_26_SDS */
69 /************************** End Band 26 Section ***************************/
70 
71 PGSt_SMF_status Reflective_Cal (int16 S,
72  L1A_granule_t *L1A_Gran,
73  L1B_granule_t *L1B_Gran,
74  L1A_Scan_t *L1A_Scan,
75  L1B_Scan_t *L1B_Scan,
77  refl_tables_t *refl_tables,
78  common_QA_tables_t *QA_tables,
79  QA_Common_t *QA_Common);
80 
81 #define BAND_5_AGGR_INDEX MODIS_BAND5_INDEX - NUM_250M_BANDS
82 #define BAND_26_1KM_INDEX NUM_1000M_REFL_BANDS - 1
83 
84 extern PGSt_SMF_status Band_26_Crosstalk_Correction (
85  L1B_Scan_t *L1B_Scan,
86  int16 *b5_frame_offset,
87 #ifdef USE_B5_RAD_OFFSET
88  float32 b5_rad_offset,
89 #endif /* USE_B5_RAD_OFFSET */
90  float32 *b26_fr_b5_scaled_corr,
91  QA_Common_t *QA_Common,
92  uint32 *valid_pixels,
93  uint32 *negative_value_below_noise_pixels,
94  int16 *bad_data_flag,
95  boolean isdaymode,
96  boolean perform_correction);
97 #endif
98 
integer, parameter int16
Definition: cubeio.f90:3
PGSt_SMF_status Reflective_Cal(int16 S, L1A_granule_t *L1A_Gran, L1B_granule_t *L1B_Gran, L1A_Scan_t *L1A_Scan, L1B_Scan_t *L1B_Scan, Preprocess_Data_t *PP, refl_tables_t *refl_tables, common_QA_tables_t *QA_tables, QA_Common_t *QA_Common)
endif() set(LIBS $
Definition: CMakeLists.txt:6
PGSt_SMF_status Band_26_Crosstalk_Correction(L1B_Scan_t *L1B_Scan, int16 *b5_frame_offset, float32 *b26_fr_b5_scaled_corr, QA_Common_t *QA_Common, uint32 *valid_pixels, uint32 *negative_value_below_noise_pixels, int16 *bad_data_flag, boolean isdaymode, boolean perform_correction)
PGSt_SMF_status Copy_Band_26_Data(L1B_Scan_t *L1B_Scan)
int32 Reflective_Cal_Band_Flag