OB.DAAC Logo
NASA Logo
Ocean Color Science Software

ocssw V2022
smeta_geometry.h
Go to the documentation of this file.
1 /*
2  * Name: smeta_geometry.c
3  *
4  * Purpose:
5  * Source file containing the functions used to relate Level 1T pixel line/sample
6  * coordinates to the corresponding viewing and solar illumination angles. These functions
7  * operate on the SMETA data type defined in "smeta.h".
8  */
9 #ifndef _SMETA_GEOMETRY_H_
10 #define _SMETA_GEOMETRY_H_
11 
12 #include "ias_math.h" /* IAS_VECTOR declaration */
13 #include "smeta.h" /* Definition of SMETA structure */
14 
16  double lat, /* Input latitude in radians */
17  double lon, /* Input longitude in radians */
18  double hgt, /* Input height in meters */
19  IAS_VECTOR *ecef ); /* Output ECEF vector */
20 
22  double lat, /* Input latitude in radians */
23  double lon, /* Input longitude in radians */
24  double ecf2lsr[3][3] ); /* ECEF to LSR rotation matrix */
25 
27  SMETA *smeta, /* Input enhanced metadata info */
28  int band, /* Input band number */
29  double proj_x, /* Input projection X coordinate */
30  double proj_y, /* Input projection Y coordinate */
31  double *l1t_line, /* Output L1T line number */
32  double *l1t_samp ); /* Output L1T sample number */
33 
35  SMETA_SCENE_PROJ proj, /* Input enhanced metadata projection info */
36  double lat, /* Input latitude (radians) */
37  double lon, /* Input longitude (radians) */
38  double *proj_x, /* Output projection X coordinate */
39  double *proj_y ); /* Output projection Y coordinate */
40 
42  SMETA_SCENE_PROJ proj ); /* Input enhanced metadata projection info */
43 
45  double inx, /* I: Input X projection coordinate */
46  double iny, /* I: Input Y projection coordinate */
47  double *outx, /* O: Output X projection coordinate */
48  double *outy ); /* O: Output Y projection coordinate */
49 
51 
53  SMETA *smeta, /* Input enhanced metadata info */
54  int band ); /* Input band number */
55 
57  SMETA *smeta, /* Enhanced metadata */
58  int band, /* Current band number */
59  double l1t_line, /* Current L1T line number */
60  double l1t_samp, /* Current L1T sample number */
61  IAS_VECTOR *satvec, /* Satellite view vector */
62  IAS_VECTOR *sunvec ); /* Solar illumination vector */
63 
64 #endif
float * hgt
subroutine sunvec(procrng, sunproc, navctl, sun_bod)
Definition: sunvec.f:2
void smeta_release_projection()
int smeta_proj_to_l1t(SMETA *smeta, int band, double proj_x, double proj_y, double *l1t_line, double *l1t_samp)
PARAM_TYPE_NONE Default value No parameter is buried in the product name name_prefix is case insensitive string compared to the product name PARAM_TYPE_VIS_WAVE The visible wavelength bands from the sensor are buried in the product name The product name is compared by appending and name_suffix ie aph_412_giop where prod_ix will be set to PARAM_TYPE_IR_WAVE same search method as PARAM_TYPE_VIS_WAVE except only wavelength above are looped through but prod_ix is still based ie aph_2_giop for the second band
float * lat
int smeta_calc_vectors(SMETA *smeta, int band, double l1t_line, double l1t_samp, IAS_VECTOR *satvec, IAS_VECTOR *sunvec)
int smeta_transform_projection(double inx, double iny, double *outx, double *outy)
int smeta_init_projection(SMETA_SCENE_PROJ proj)
subroutine ecef(gha, posi, veli, pose, vele)
Definition: ecef.f:2
int smeta_band_number_to_index(SMETA *smeta, int band)
int smeta_geodetic_to_ecf2lsr(double lat, double lon, double ecf2lsr[3][3])
float * lon
Definition: smeta.h:118
int smeta_geodetic_to_ecef(double lat, double lon, double hgt, IAS_VECTOR *ecef)
int smeta_geodetic_to_proj(SMETA_SCENE_PROJ proj, double lat, double lon, double *proj_x, double *proj_y)