PostGIS  3.0.6dev-r@@SVN_REVISION@@

◆ encode_keys()

static void encode_keys ( mvt_agg_context ctx)
static

Definition at line 392 of file mvt.c.

393 {
394  struct mvt_kv_key *kv;
395  size_t n_keys = ctx->keys_hash_i;
396  char **keys = palloc(n_keys * sizeof(*keys));
397  for (kv = ctx->keys_hash; kv != NULL; kv=kv->hh.next)
398  keys[kv->id] = kv->name;
399  ctx->layer->n_keys = n_keys;
400  ctx->layer->keys = keys;
401 
402  HASH_CLEAR(hh, ctx->keys_hash);
403 }
VectorTile__Tile__Layer * layer
Definition: mvt.h:67
uint32_t keys_hash_i
Definition: mvt.h:78
struct mvt_kv_key * keys_hash
Definition: mvt.h:70
uint32_t id
Definition: mvt.c:66
UT_hash_handle hh
Definition: mvt.c:67
char * name
Definition: mvt.c:65
Definition: mvt.c:64

References mvt_kv_key::hh, mvt_kv_key::id, mvt_agg_context::keys_hash, mvt_agg_context::keys_hash_i, mvt_agg_context::layer, and mvt_kv_key::name.

Referenced by mvt_ctx_to_tile().

Here is the caller graph for this function: