GRASS GIS 8 Programmer's Manual  8.5.0dev(2024)-602118adcc
raster3d/range.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include <unistd.h>
#include <grass/gis.h>
#include <grass/raster.h>
#include <grass/glocale.h>
#include "raster3d_intern.h"
Include dependency graph for raster3d/range.c:

Go to the source code of this file.

Functions

void Rast3d_range_update_from_tile (RASTER3D_Map *map, const void *tile, int rows, int cols, int depths, int xRedundant, int yRedundant, int zRedundant UNUSED, int nofNum, int type)
 
int Rast3d_read_range (const char *name, const char *mapset, struct FPRange *drange)
 
int Rast3d_range_load (RASTER3D_Map *map)
 Loads the range into the range structure of map. More...
 
void Rast3d_range_min_max (RASTER3D_Map *map, double *min, double *max)
 Returns in min and max the minimum and maximum values of the range. More...
 
int Rast3d_range_write (RASTER3D_Map *map)
 Writes the range which is stored in the range structure of map. (This function is invoked automatically when a new file is closed). More...
 
int Rast3d_range_init (RASTER3D_Map *map)
 

Function Documentation

◆ Rast3d_range_init()

int Rast3d_range_init ( RASTER3D_Map map)

Definition at line 203 of file raster3d/range.c.

References RASTER3D_Map::range, and Rast_init_fp_range().

Referenced by Rast3d_open_cell_old_no_header().

◆ Rast3d_range_load()

int Rast3d_range_load ( RASTER3D_Map map)

Loads the range into the range structure of map.

Parameters
mapa pointer to a raster 3D map object
Returns
1 ... if successful 0 ... otherwise.

Definition at line 109 of file raster3d/range.c.

References RASTER3D_Map::fileName, RASTER3D_Map::mapset, RASTER3D_Map::operation, RASTER3D_Map::range, Rast3d_read_range(), and RASTER3D_WRITE_DATA.

◆ Rast3d_range_min_max()

void Rast3d_range_min_max ( RASTER3D_Map map,
double *  min,
double *  max 
)

Returns in min and max the minimum and maximum values of the range.

Parameters
mapa pointer to a raster 3D map object
mina pointer to a double to store minumim
maxa pointer to a double to store maximum

Definition at line 131 of file raster3d/range.c.

References max, min, RASTER3D_Map::range, and Rast_get_fp_range_min_max().

Referenced by Rast3d_print_header().

◆ Rast3d_range_update_from_tile()

void Rast3d_range_update_from_tile ( RASTER3D_Map map,
const void *  tile,
int  rows,
int  cols,
int  depths,
int  xRedundant,
int  yRedundant,
int zRedundant  UNUSED,
int  nofNum,
int  type 
)

Definition at line 14 of file raster3d/range.c.

◆ Rast3d_range_write()

int Rast3d_range_write ( RASTER3D_Map map)

Writes the range which is stored in the range structure of map. (This function is invoked automatically when a new file is closed).

Parameters
map
Returns
1 ... if successful 0 ... otherwise.

Definition at line 186 of file raster3d/range.c.

References RASTER3D_Map::fileName, GPATH_MAX, RASTER3D_Map::mapset, Rast3d_filename(), and RASTER3D_RANGE_ELEMENT.

◆ Rast3d_read_range()

int Rast3d_read_range ( const char *  name,
const char *  mapset,
struct FPRange drange 
)