20 #include <grass/N_pde.h> 82 "N_init_geom_data_3d: initializing the geometry structure");
128 "N_init_geom_data_2d: initializing the geometry structure");
149 geom->
Az = geom->
dy * geom->
dx;
158 "N_init_geom_data_2d: calculating the areas for non parametric projection");
167 for (i = 0; i < geom->
rows; i++) {
195 G_debug(6,
"N_get_geom_data_area_of_cell: %g", geom->
Az);
199 G_debug(6,
"N_get_geom_data_area_of_cell: %g", geom->
area[row]);
200 return geom->
area[row];
2D/3D raster map header (used also for region)
void G_free(void *)
Free allocated memory.
void Rast_set_window(struct Cell_head *)
Establishes 'window' as the current working window.
N_geom_data * N_init_geom_data_2d(struct Cell_head *region, N_geom_data *geodata)
Initiate a pde geometry data structure with a 2d region.
Geometric information about the structured grid.
void G_get_set_window(struct Cell_head *)
Get the current working window (region)
double N_get_geom_data_area_of_cell(N_geom_data *geom, int row)
Get the areay size in square meter of one cell (x*y) at row.
int G_begin_cell_area_calculations(void)
Begin cell area calculations.
N_geom_data * N_alloc_geom_data(void)
Allocate the pde geometry data structure and return a pointer to the new allocated structure...
int cols
Number of columns for 2D data.
double ns_res
Resolution - north to south cell size for 2D data.
void N_free_geom_data(N_geom_data *geom)
Release memory of a pde geometry data structure.
double G_database_units_to_meters_factor(void)
Conversion to meters.
void Rast3d_region_to_cell_head(RASTER3D_Region *, struct Cell_head *)
Returns in region2d the 2d portion of region3d.
N_geom_data * N_init_geom_data_3d(RASTER3D_Region *region3d, N_geom_data *geodata)
Initiate a pde geometry data structure with a 3d region.
double ew_res
Resolution - east to west cell size for 2D data.
double G_area_of_cell_at_row(int)
Cell area in specified row.
int rows
Number of rows for 2D data.
int G_debug(int, const char *,...) __attribute__((format(printf