From 2e434e5d4c2b8ee6f9603237526c762e5d10ae7c Mon Sep 17 00:00:00 2001 From: Eugen Betke Date: Fri, 14 Apr 2023 09:42:34 +0000 Subject: [PATCH] ECC-1472: complex_context -> bitstream_context --- src/grib_accessor_class_data_g22order_packing.cc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/grib_accessor_class_data_g22order_packing.cc b/src/grib_accessor_class_data_g22order_packing.cc index 704c2c432..c04e34afd 100644 --- a/src/grib_accessor_class_data_g22order_packing.cc +++ b/src/grib_accessor_class_data_g22order_packing.cc @@ -235,20 +235,20 @@ static void init(grib_accessor* a, const long v, grib_arguments* args) #define DEFINED_VAL(x) ((x) < UNDEFINED_LOW || (x) > UNDEFINED_HIGH) #define UNDEFINED_ANGLE 999.0 -struct complex_context { +struct bitstream_context { unsigned char* bitstream; int rbits; int reg; int n_bitstream; }; -static void init_bitstream(complex_context *ctx, unsigned char* new_bitstream) +static void init_bitstream(bitstream_context *ctx, unsigned char* new_bitstream) { ctx->bitstream = new_bitstream; ctx->n_bitstream = ctx->reg = ctx->rbits = 0; } -static void finish_bitstream(complex_context *ctx) +static void finish_bitstream(bitstream_context *ctx) { if (ctx->rbits) { ctx->n_bitstream++; @@ -257,7 +257,7 @@ static void finish_bitstream(complex_context *ctx) } } -static void add_many_bitstream(complex_context *ctx, grib_accessor* a, int* t, int n, int n_bits) +static void add_many_bitstream(bitstream_context *ctx, grib_accessor* a, int* t, int n, int n_bits) { unsigned int jmask; int i; @@ -281,7 +281,7 @@ static void add_many_bitstream(complex_context *ctx, grib_accessor* a, int* t, i } } -static void add_bitstream(complex_context *ctx, grib_accessor* a, int t, int n_bits) +static void add_bitstream(bitstream_context *ctx, grib_accessor* a, int t, int n_bits) { unsigned int jmask; const int max_numbits = 25; @@ -1868,7 +1868,7 @@ static int pack_double(grib_accessor* a, const double* val, size_t* len) // pack the values into a bitstream - complex_context ctx; + bitstream_context ctx; init_bitstream(&ctx, sec7); add_bitstream(&ctx, a, size_sec7 >> 16, 16); add_bitstream(&ctx, a, size_sec7, 16);