|
NCEPLIBS-g2
3.4.7
|
This subroutine packs up a GRIB2 data field. More...
Go to the source code of this file.
Functions/Subroutines | |
| subroutine | compack (fld, ndpts, idrsnum, idrstmpl, cpack, lcpack) |
| This subroutine supports GRIB2 complex packing templates with or without spatial differences, Data Representation Templates (DRT) [GRIB2 - DATA REPRESENTATION TEMPLATE 5.2 - Grid point data - complex packing](https://www.nco.ncep.noaa.gov/pmb/docs/grib2/grib2_doc/grib2_temp5-2.shtml) and [GRIB2 - DATA REPRESENTATION TEMPLATE 5.3 - Grid point data - complex packing and spatial differencing](https://www.nco.ncep.noaa.gov/pmb/docs/grib2/grib2_doc/grib2_temp5-3.shtml). More... | |
| subroutine compack | ( | real, dimension(ndpts), intent(in) | fld, |
| integer, intent(in) | ndpts, | ||
| integer, intent(in) | idrsnum, | ||
| integer, dimension(*), intent(inout) | idrstmpl, | ||
| character(len=1), dimension(*), intent(out) | cpack, | ||
| integer, intent(out) | lcpack | ||
| ) |
This subroutine supports GRIB2 complex packing templates with or without spatial differences, Data Representation Templates (DRT) [GRIB2 - DATA REPRESENTATION TEMPLATE 5.2 - Grid point data - complex packing](https://www.nco.ncep.noaa.gov/pmb/docs/grib2/grib2_doc/grib2_temp5-2.shtml) and [GRIB2 - DATA REPRESENTATION TEMPLATE 5.3 - Grid point data - complex packing and spatial differencing](https://www.nco.ncep.noaa.gov/pmb/docs/grib2/grib2_doc/grib2_temp5-3.shtml).
It also fills in GRIB2 Data Representation Template 5.2 or 5.3 with the appropriate values.
| [in] | fld | The data values to pack. |
| [in] | ndpts | The number of data values in array fld. |
| [in] | idrsnum | Data Representation Template number - must equal 2 or 3. |
| [in,out] | idrstmpl | The array of values for Data Representation Template 5.2 or 5.3.
|
| [out] | cpack | The packed data field (character*1 array). |
| [out] | lcpack | length of packed field cpack. |
Definition at line 34 of file compack.f.
References g2_sbytec(), g2_sbytesc(), mkieee(), and pack_gp().
Referenced by cmplxpack().