aecunpack.c(3)
π aecunpack.c β the aecunpack.c(3) page, bestie edition π
okay so this is aecunpack.c(3) from the Library Functions Manual, and it's literally all about unpacking a data field that was packed with AEC compression. yes bestie, we're un-squishing data. it's giving β¨reverse magicβ¨.
β¨ NAME β¨
aecunpack.c β Unpack a data field that was packed with AEC compression.
π SYNOPSIS π
#include 'grib2_int.h'
#include <stdio.h>
#include <stdlib.h>
π¦ Functions
g2int aecunpack (unsigned char *cpack, g2int len, g2int *idrstmpl, g2int ndpts, float *fld)β Unpack AEC compressed data into an array of floats, using info from the GRIB2 Data Representation Template 5.42.static int aecunpack_int (unsigned char *cpack, g2int len, g2int *idrstmpl, g2int ndpts, void *fld, int fld_is_double, int verbose)β Unpack AEC compressed data into an array of floats or doubles, using info from the GRIB2 Data Representation Template 5.42.int g2c_aecunpackd (unsigned char *cpack, size_t len, int *idrstmpl, size_t ndpts, double *fld)β Unpack AEC compressed data into an array of doubles, using info from the GRIB2 Data Representation Template 5.42.int g2c_aecunpackf (unsigned char *cpack, size_t len, int *idrstmpl, size_t ndpts, float *fld)β Unpack AEC compressed data into an array of floats, using info from the GRIB2 Data Representation Template 5.42.
πΈ Detailed Description πΈ
Unpack a data field that was packed with AEC compression.
stream
π Author
Eric Engle
π Date
2023-10-16
Definition in file aecunpack.c.
π Function Documentation π
g2int aecunpack (unsigned char * cpack, g2int len, g2int * idrstmpl, g2int ndpts, float * fld)
Unpack AEC compressed data into an array of floats, using info from the GRIB2 Data Representation Template 5.42.
π«Ά Parameters
cpackβ The packed data.lenβ The length of the packed data.idrstmplβ Pointer to array of values for Data Representation Template 5.42.ndptsβ The number of data values to unpack.fldβ A pointer that gets the unpacked data values as an array offloat.
β Returns
G2C_NOERRORβ No error.
π Author
Eric Engle
π Date
2023-10-16
Definition at line 161 of file aecunpack.c.
References aecunpack_int(), and LOG.
Referenced by g2c_unpack7_int().
int aecunpack_int (unsigned char * cpack, g2int len, g2int * idrstmpl, g2int ndpts, void * fld, int fld_is_double, int verbose) [static]
Unpack AEC compressed data into an array of floats or doubles, using info from the GRIB2 Data Representation Template 5.42. This function is used by aecunpack(), g2c_aecunpackf(), and g2c_aecunpackd().
π«Ά Parameters
cpackβ The packed data.lenβ The length of the packed data.idrstmplβ Pointer to array of values for Data Representation Template 5.42.ndptsβ The number of data values to unpack.fldβ A pointer that gets the unpacked data values.fld_is_doubleβ Non-zero if the data are to be unpacked into adoublearray, otherwise data will be unpacked into afloatarray.verboseβ If non-zero, error messages will be printed in case of error. Otherwise, error codes will be return but no error messages printed. Calls to the originalg2cAPI may cause error messages to be printed in case of error. For the newg2c_API, no error messages will be printed - instead an error code will be returned. Callg2c_strerror()to get the error message for any error code.
β Returns
G2C_NOERRORβ No error.G2C_ENOMEMβ Out of memory.
π Author
Eric Engle
π Date
2023-10-16
Definition at line 43 of file aecunpack.c.
References dec_aec(), G2C_ENOMEM, G2C_NOERROR, gbits(), int_power(), LOG, and rdieee().
Referenced by aecunpack(), g2c_aecunpackd(), and g2c_aecunpackf().
int g2c_aecunpackd (unsigned char * cpack, size_t len, int * idrstmpl, size_t ndpts, double * fld)
Unpack AEC compressed data into an array of doubles, using info from the GRIB2 Data Representation Template 5.42. This function is the V2 API version of aecunpack() for doubles.
π«Ά Parameters
cpackβ The packed data.lenβ The length of the packed data.idrstmplβ Pointer to array of values for Data Representation Template 5.42.ndptsβ The number of data values to unpack.fldβ A pointer that gets the unpacked data values as an array ofdouble.
β Returns
G2C_NOERRORβ No error.G2C_ENOMEMβ Out of memory.
π Author
Eric Engle
π Date
2023-10-16
Definition at line 232 of file aecunpack.c.
References aecunpack_int(), G2C_AEC_DRS_TEMPLATE_LEN, and LOG.
int g2c_aecunpackf (unsigned char * cpack, size_t len, int * idrstmpl, size_t ndpts, float * fld)
Unpack AEC compressed data into an array of floats, using info from the GRIB2 Data Representation Template 5.42.
π«Ά Parameters
cpackβ The packed data.lenβ The length of the packed data.idrstmplβ Pointer to array of values for Data Representation Template 5.42.ndptsβ The number of data values to unpack.fldβ A pointer that gets the unpacked data values as an array offloat.
β Returns
G2C_NOERRORβ No error.G2C_ENOMEMβ Out of memory.
π Author
Eric Engle
π Date
2022-10-16
Definition at line 194 of file aecunpack.c.
References aecunpack_int(), G2C_AEC_DRS_TEMPLATE_LEN, and LOG.
π Author π
Generated automatically by Doxygen for NCEPLIBS-g2c from the source code.
and that's the whole page, bestie!! πβ¨ this one came from NCEPLIBS-g2c, Version 2.3.0, and the footer date on the original is aecunpack.c(3) β slay, go unpack some data, you've got this π«Άπ
π¦ where this page comes from
- ubuntu resolute: libg2c-dev 2.3.0-4 Β· LGPL-3.0-only
- ubuntu stonking: libg2c-dev 2.3.0-7 Β· LGPL-3.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms