GRASS Programmer's Manual  6.4.2(2012)
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
getblock.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include <unistd.h>
#include "G3d_intern.h"
Include dependency graph for getblock.c:

Go to the source code of this file.

Functions

void G3d_getBlockNocache (G3D_Map *map, int x0, int y0, int z0, int nx, int ny, int nz, void *block, int type)
void G3d_getBlock (G3D_Map *map, int x0, int y0, int z0, int nx, int ny, int nz, void *block, int type)
 Copies the cells contained in the block (cube) with vertices (x0, y0, z0) and (x0 + nx - 1, y0 + ny - 1, z0 + nz - 1) into block. The cell-values in block are of type. The source code can be found in getblock.c.

Function Documentation

void G3d_getBlock ( G3D_Map *  map,
int  x0,
int  y0,
int  z0,
int  nx,
int  ny,
int  nz,
void *  block,
int  type 
)

Copies the cells contained in the block (cube) with vertices (x0, y0, z0) and (x0 + nx - 1, y0 + ny - 1, z0 + nz - 1) into block. The cell-values in block are of type. The source code can be found in getblock.c.

Parameters:
map
x0
y0
z0
nx
ny
nz
block
type
Returns:
void

Definition at line 103 of file getblock.c.

References G3d_getBlockNocache(), G3d_getValueRegion(), G3d_length(), G3D_MIN, G3d_setNullValue(), and G_incr_void_ptr().

void G3d_getBlockNocache ( G3D_Map *  map,
int  x0,
int  y0,
int  z0,
int  nx,
int  ny,
int  nz,
void *  block,
int  type 
)