NCEPLIBS-g2c  1.6.4
cmplxpack.c
Go to the documentation of this file.
1 
7 #include "grib2.h"
8 
34 void
35 cmplxpack(g2float *fld, g2int ndpts, g2int idrsnum, g2int *idrstmpl,
36  unsigned char *cpack, g2int *lcpack)
37 {
38  if (idrstmpl[6] == 0) /* No internal missing values */
39  compack(fld, ndpts, idrsnum, idrstmpl, cpack, lcpack);
40  else if (idrstmpl[6] == 1 || idrstmpl[6] == 2)
41  misspack(fld, ndpts, idrsnum, idrstmpl, cpack, lcpack);
42  else
43  {
44  printf("cmplxpack: Don:t recognize Missing value option.");
45  *lcpack = -1;
46  }
47 
48 }
void cmplxpack(g2float *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 docum...
Definition: cmplxpack.c:35
void compack(g2float *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 docum...
Definition: compack.c:42
Header file for NCEPLIBS-g2c library.
float g2float
Float type.
Definition: grib2.h:22
int64_t g2int
Long integer type.
Definition: grib2.h:20
void misspack(g2float *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 docum...
Definition: misspack.c:43