Go to the documentation of this file.
7 static int (*interp_height)(
float *
xlon,
float *
xlat,
float *height);
18 static int (*correct_terrain)(
32 static int firstCall = 1;
38 float *height = &
l1rec->height[ip];
58 fprintf(
stderr,
"-E- %s line %d: "
59 "Elevation file is NULL.\n",
63 printf(
"Loading DEM info from %s\n",
input->demfile);
66 if(Hishdf(
input->demfile))
69 status = nc_open(
input->demfile, NC_NOWRITE, &ncid);
71 netcdf_dem = (
status == NC_NOERR);
72 if (netcdf_dem) nc_close(ncid);
90 fprintf(
stderr,
"-E- %s line %d: interp_height():\n",
93 "xlon=%f xlat=%f height=%f\n",
94 (
double) *
xlon, (
double) *
xlat, (
double) *height);
102 fprintf(
stderr,
"-E- %s line %d: correct_terrain():\n",
105 "xlon=%f xlat=%f senz=%f sena=%f height=%f\n",
107 (
double) *
senz, (
double) *
sena, (
double) *height);
110 float senz_corr = *
senz - senz_sav;
111 int32_t nwave =
l1rec->l1file->nbands, iw;
112 for (iw = 0; iw < nwave; iw++) {
113 l1rec->geom_per_band->senz[ ip * nwave + iw ] += senz_corr;
int interp_dem_height(float *xlon, float *xlat, float *height)
int get_height(l1str *l1rec, int32_t ip, int terrain_corrected)
int get_nc_height(float *lon, float *lat, float *senz, float *sena, float *height)
int interp_nc_height(float *xlon, float *xlat, float *height)
int get_dem_height(float *lon, float *lat, float *senz, float *sena, float *height)
float xlon[LAC_PIXEL_NUM]