|
ocssw
V2022
|
#include "geo_region.h"#include "l12_proto.h"#include <netcdf>#include <string>#include <iostream>#include <vector>
Include dependency graph for geo_region.cpp:
Go to the source code of this file.
Macros | |
| #define | ERROR_EXIT |
| #define | CHECK_BOUNDS(max_val, min_val) |
Functions | |
| void | read_variable (const netCDF::NcFile &file, netCDF::NcVar &var, const std::string &varname) |
| void | close_georegion_file () |
| int | get_georegion (float lat, float lon) |
Macro Definition Documentation
◆ CHECK_BOUNDS
| #define CHECK_BOUNDS | ( | max_val, | |
| min_val | |||
| ) |
Value:
{ \
if (min_val > max_val) { \
std::cerr << "--Error--: " << #min_val << "=" << min_val << " is larger than " << #max_val << "=" \
<< max_val; \
ERROR_EXIT; \
} \
}
Definition at line 14 of file geo_region.cpp.
◆ ERROR_EXIT
| #define ERROR_EXIT |
Value:
{ \
std::cerr << "\n See " << __LINE__ << " in file " << __FILE__ << ". Exiting...\n"; \
georegion_file.close(); \
exit(EXIT_FAILURE); \
}
Definition at line 8 of file geo_region.cpp.
Function Documentation
◆ close_georegion_file()
| void close_georegion_file | ( | ) |
Definition at line 47 of file geo_region.cpp.
◆ get_georegion()
| int get_georegion | ( | float | lat, |
| float | lon | ||
| ) |
Definition at line 51 of file geo_region.cpp.
◆ read_variable()
| void read_variable | ( | const netCDF::NcFile & | file, |
| netCDF::NcVar & | var, | ||
| const std::string & | varname | ||
| ) |
Definition at line 39 of file geo_region.cpp.


