decenc_aec.c(3)

πŸ“¦
version 2.3.0 Β· 2 versions
, in ubuntu resolute, ubuntu stonking

πŸ’– decenc_aec.c β€” Library Functions Manual πŸ’–

okay bestie, pull up a chair, because we're decoding AND encoding AEC code streams today and it's honestly giving main character energy. this whole page lives in decenc_aec.c(3) β€” that's the manpage name, the whole Library Functions Manual vibe, and yes we're gonna read all of it together. no skimming, no cap. πŸ¦‹


✨ NAME ✨

decenc_aec.c β€” Decode/encode an AEC code stream.


🌸 SYNOPSIS 🌸

#include 'grib2_int.h'
#include <libaec.h>
#include <stdint.h>
#include <stdio.h>

πŸŽ€ Functions

  • int dec_aec (unsigned char *cpack, g2int len, g2int nbits, g2int flags, g2int block_size, g2int rsi, unsigned char *cfld, g2int cfldlen) β€” Decode an AEC code stream specified in the CCSDS 121.0-B-3 Blue Book.
  • int enc_aec (unsigned char *data, g2int ctemplen, g2int nbits, g2int flags, g2int block_size, g2int rsi, unsigned char *aecbuf, g2int *aecbuflen) β€” Encode data into an AEC code stream specified in the CCSDS 121.0-B-3 Blue Book.
  • int g2c_dec_aec (unsigned char *cpack, int len, int nbits, int flags, int block_size, int rsi, unsigned char *cfld, int cfldlen) β€” Decode an AEC code stream specified in the CCSDS 121.0-B-3 Blue Book.
  • int g2c_enc_aec (unsigned char *data, int ctemplen, int nbits, int flags, int block_size, int rsi, unsigned char *aecbuf, int *aecbuflen) β€” Encode data into an AEC code stream specified in the CCSDS 121.0-B-3 Blue Book.

πŸ’… Detailed Description πŸ’…

Decode/encode an AEC code stream. that's the whole vibe, and honestly? iconic. ✨

Author Eric Engle

Date 2023-10-16

Definition in file decenc_aec.c.


πŸ‘‘ Function Documentation πŸ‘‘

⭐ int dec_aec (unsigned char * cpack, g2int len, g2int nbits, g2int flags, g2int block_size, g2int rsi, unsigned char * cfld, g2int cfldlen)

Decode an AEC code stream specified in the CCSDS 121.0-B-3 Blue Book. literally what it says on the tin, bestie. πŸ’–

Parameters

  • cpack β€” Pointer to buffer that holds the input AEC code stream.
  • len β€” Length (in bytes) of the buffer that holds the input AEC code stream.
  • nbits β€” CCSDS bits per sample.
  • flags β€” CCSDS compression options mask.
  • block_size β€” CCSDS block size.
  • rsi β€” CCSDS reference sample interval.
  • cfld β€” Pointer to output buffer from the AEC decoder.
  • cfldlen β€” length of output buffer.

Returns

  • >0 β€” Length of data from AEC decoder
  • 0 β€” Successful decode (AEC_OK)
  • -1 β€” AEC_CONF_ERROR
  • -2 β€” AEC_STREAM_ERROR
  • -3 β€” AEC_DATA_ERROR
  • -4 β€” AEC_MEM_ERROR
  • -5 β€” AEC_RSI_OFFSETS_ERROR

Author Eric Engle

Date 2023-10-16

Definition at line 38 of file decenc_aec.c.

References LOG.

Referenced by aecunpack_int(), and g2c_dec_aec().


πŸ¦‹ int enc_aec (unsigned char * data, g2int ctemplen, g2int nbits, g2int flags, g2int block_size, g2int rsi, unsigned char * aecbuf, g2int * aecbuflen)

Encode data into an AEC code stream specified in the CCSDS 121.0-B-3 Blue Book. the other half of the glow-up, periodt. πŸ”₯

Parameters

  • data β€” Pointer to buffer that holds the input data.
  • ctemplen β€” Length (in bytes) of the buffer that holds the input data.. (yes, two dots, that's what it says, i don't make the rules πŸ™ˆ)
  • nbits β€” CCSDS bits per sample.
  • flags β€” CCSDS compression options mask.
  • block_size β€” CCSDS block size.
  • rsi β€” CCSDS reference sample interval.
  • aecbuf β€” Pointer to buffer holding the AEC encoded stream.
  • aecbuflen β€” Length of AEC code stream.

Returns

  • >0 β€” Exact length of AEC encoded data.
  • 0 β€” Successful decode (AEC_OK)
  • -1 β€” AEC_CONF_ERROR
  • -2 β€” AEC_STREAM_ERROR
  • -3 β€” AEC_DATA_ERROR
  • -4 β€” AEC_MEM_ERROR
  • -5 β€” AEC_RSI_OFFSETS_ERROR

Author Eric Engle

Date 2023-10-16

Definition at line 108 of file decenc_aec.c.

References LOG.

Referenced by aecpack_int(), and g2c_enc_aec().


🌈 int g2c_dec_aec (unsigned char * cpack, int len, int nbits, int flags, int block_size, int rsi, unsigned char * cfld, int cfldlen)

Decode an AEC code stream specified in the CCSDS 121.0-B-3 Blue Book. same energy, just with int instead of g2int, iykyk. ✨

Parameters

  • cpack β€” Pointer to buffer that holds the input AEC code stream.
  • len β€” Length (in bytes) of the buffer that holds the input AEC code stream.
  • nbits β€” CCSDS bits per sample.
  • flags β€” CCSDS compression options mask.
  • block_size β€” CCSDS block size.
  • rsi β€” CCSDS reference sample interval.
  • cfld β€” Pointer to output buffer from the AEC decoder.
  • cfldlen β€” length of output buffer.

Returns

  • >0 β€” Length of data from AEC decoder
  • 0 β€” Successful decode (AEC_OK)
  • -1 β€” AEC_CONF_ERROR
  • -2 β€” AEC_STREAM_ERROR
  • -3 β€” AEC_DATA_ERROR
  • -4 β€” AEC_MEM_ERROR
  • -5 β€” AEC_RSI_OFFSETS_ERROR

Author Alyson Stahl

Date 10/2025

Definition at line 179 of file decenc_aec.c.

References dec_aec().


πŸ“ int g2c_enc_aec (unsigned char * data, int ctemplen, int nbits, int flags, int block_size, int rsi, unsigned char * aecbuf, int * aecbuflen)

Encode data into an AEC code stream specified in the CCSDS 121.0-B-3 Blue Book. she's the int-flavored twin and she ate. πŸ’…

Parameters

  • data β€” Pointer to buffer that holds the input data.
  • ctemplen β€” Length (in bytes) of the buffer that holds the input data.. (again with the double dot, i'm just the messenger 😭)
  • nbits β€” CCSDS bits per sample.
  • flags β€” CCSDS compression options mask.
  • block_size β€” CCSDS block size.
  • rsi β€” CCSDS reference sample interval.
  • aecbuf β€” Pointer to buffer holding the AEC encoded stream.
  • aecbuflen β€” Length of AEC code stream.

Returns

  • >0 β€” Exact length of AEC encoded data.
  • 0 β€” Successful decode (AEC_OK)
  • -1 β€” AEC_CONF_ERROR
  • -2 β€” AEC_STREAM_ERROR
  • -3 β€” AEC_DATA_ERROR
  • -4 β€” AEC_MEM_ERROR
  • -5 β€” AEC_RSI_OFFSETS_ERROR

Author Alyson Stahl

Date 10/2025

Definition at line 215 of file decenc_aec.c.

References enc_aec().


🫢 Author 🫢

Generated automatically by Doxygen for NCEPLIBS-g2c from the source code.


k that's the whole page bestie, every flag, every param, every return code, all present and accounted for. nothing skipped, nothing invented. slay. πŸ’–

so this little love letter to AEC streams is from NCEPLIBS-g2c, Version 2.3.0, and that's the whole decenc_aec.c(3) situation β€” go decode something iconic. mwah. πŸŒΈπŸ’…βœ¨

πŸ“¦ where this page comes from