NCEPLIBS-g2c
1.7.0
|
Pack up a data field using a complex packing algorithm as defined in the GRIB2 documention. More...
#include "grib2_int.h"
Go to the source code of this file.
Functions | |
void | cmplxpack (float *fld, g2int ndpts, g2int idrsnum, g2int *idrstmpl, unsigned char *cpack, g2int *lcpack) |
This subroutine packs up a data field using a complex packing algorithm as defined in the GRIB2 documention. More... | |
Pack up a data field using a complex packing algorithm as defined in the GRIB2 documention.
Definition in file cmplxpack.c.
void cmplxpack | ( | float * | fld, |
g2int | ndpts, | ||
g2int | idrsnum, | ||
g2int * | idrstmpl, | ||
unsigned char * | cpack, | ||
g2int * | lcpack | ||
) |
This subroutine packs up a data field using a complex packing algorithm as defined in the GRIB2 documention.
It supports GRIB2 complex packing templates with or without spatial differences (i.e. DRTs 5.2 and 5.3). It also fills in GRIB2 Data Representation Template 5.2 or 5.3 with the appropriate values.
fld | Contains the data values to pack. |
ndpts | The number of data values in array fld |
idrsnum | Data Representation Template number. Must equal 2 or 3. |
idrstmpl | Contains the array of values for Data Representation Template 5.2 or 5.3
|
cpack | The packed data field. |
lcpack | length of packed field cpack. Will be set to -1 if missing value management field is not 1 or 2. |
Definition at line 36 of file cmplxpack.c.
References compack(), and misspack().
Referenced by g2_addfield().