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.10 2006-10-30 10:00:14-05 ltan
21  Changed for ANSI-C compliance. Correction for the generation of code change log.
22 
23  Revision 1.02 April 25, 2003 Razor Issue # 190
24  Removed passed parameter L1A_Gran from Band_26_Crosstalk_Correction; no longer needed to
25  differentiate which platform is being processed because procedure is now applied to
26  MODIS/Aqua as well.
27  Alice Isaacman SAIC GSO (Alice.R.Isaacman.1@gsfc.nasa.gov)
28 
29  Revision 01.20 March 19, 2002 Razor Issue #182
30  For MODIS/TERRA (PFM) processing only:
31  Added function prototype for Band_26_Crosstalk_Correction
32  Alice Isaacman SAIC GSO (Alice.R.Isaacman.1@gsfc.nasa.gov)
33 
34  Revision 01.10 May 13, 1999
35  Added band 26 section
36  Jim Rogers (rogers@mcst.gsfc.nasa.gov)
37 
38  Revision 01.01 Feb 17, 1999
39  Moved DN_to_DN_star to Preprocess.h as part of moving DN_to_DN_star
40  to Preprocess.c to avoid circular include dependencies.
41  Jim Rogers (rogers@mcst.gsfc.nasa.gov)
42 
43  Revision 01.00 Nov 1998
44  initial development
45  Zhenying Gu (zgu@mcst.gsfc.nasa.gov)
46 
47 !References and Credits:
48  This software is developed by the MODIS Characterization Support
49  Team (MCST) for the National Aeronautics and Space Administration,
50  Goddard Space Flight Center, under contract NAS5-32373.
51 
52  HDF portions developed at the National Center for Supercomputing
53  Applications at the University of Illinois at Urbana-Champaign.
54 
55 !Design Notes:
56 
57 !END********************************************************************
58 */
59 
60 /************************* Begin Band 26 Section **************************/
61 #ifdef WRITE_BAND_26_SDS
62 
63 /* Use the external variable Reflective_Cal_Band_Flag to signal to
64  * Reflective_Cal whether we should calculate only band 26 or all
65  * reflective bands. The macros ALL_REFLECTIVE_BANDS and
66  * REFLECTIVE_BAND_26_ONLY are the allowable values for
67  * Reflective_Cal_Band_Flag.
68  */
69 #define ALL_REFLECTIVE_BANDS 1
70 #define REFLECTIVE_BAND_26_ONLY 2
71 extern int32 Reflective_Cal_Band_Flag;
72 extern PGSt_SMF_status Copy_Band_26_Data (L1B_Scan_t *L1B_Scan);
73 
74 #endif /* WRITE_BAND_26_SDS */
75 /************************** End Band 26 Section ***************************/
76 
77 PGSt_SMF_status Reflective_Cal (int16 S,
78  L1A_granule_t *L1A_Gran,
79  L1B_granule_t *L1B_Gran,
80  L1A_Scan_t *L1A_Scan,
81  L1B_Scan_t *L1B_Scan,
83  refl_tables_t *refl_tables,
84  common_QA_tables_t *QA_tables,
85  QA_Common_t *QA_Common);
86 
87 #define BAND_5_AGGR_INDEX MODIS_BAND5_INDEX - NUM_250M_BANDS
88 #define BAND_26_1KM_INDEX NUM_1000M_REFL_BANDS - 1
89 
90 extern PGSt_SMF_status Band_26_Crosstalk_Correction (
91  L1B_Scan_t *L1B_Scan,
92  int16 *b5_frame_offset,
93 #ifdef USE_B5_RAD_OFFSET
94  float32 b5_rad_offset,
95 #endif /* USE_B5_RAD_OFFSET */
96  float32 *b26_fr_b5_scaled_corr,
97  QA_Common_t *QA_Common,
98  uint32 *valid_pixels,
99  uint32 *negative_value_below_noise_pixels,
100  int16 *bad_data_flag,
101  boolean isdaymode,
102  boolean perform_correction);
103 #endif
104 
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