wgrib2: py_wgrib2api
Introduction:
Pywgrib2_s calls the C library, wgrib2lib. It is limited to calling these wgrib2 routines
specific routines. Sure the python code could call other routines in wgrib2lib but it
is not advised. The other routines in wgrib2lib should be considered internal routines
that may change or even disappear.
Convention: pywgrib2_s only uses routines that start with wgrib2.
int wgrib2(int argc, char **argv)
call to wgrib2 routine
int wgrib2_free_file(char *filename)
frees the file, filename
REGISTER
int wgrib2_get_regsize(int i)
return number of elements in register i
int wgrib2_get_reg_data(float *data, size_t size, int i)
size = number of elements of data
gets contents of register i
int wgrib2_set_reg(float *data, size_t size size, int i)
size = number of elements of data
sets contents of register i
MEMORY BUFFER
int wgrib2_get_mem_buffer_size(int i)
return size in bytes of buffer i
int wgrib2_set_mem_buffer(unsigned char *buffer, size_t size, int ii)
size = size of buffer (bytes)
i = buffer number
int wgrib2_get_mem_buffer(unsigned char *buffer, size_t size, int i)
size = size of buffer (bytes)
i = buffer number
|