[postgis-devel] ST_AsMVT

Sandro Santilli strk at kbt.io
Sat Sep 17 08:09:27 PDT 2016


On Sat, Sep 17, 2016 at 04:25:06PM +0200, Björn Harrtell wrote:

> Found https://github.com/mapbox/vector-tile-spec/issues/11 supporting the
> claim that a multi-layered vector tile is indeed a set of independent layer
> messages. Still not sure about the possibility of aggregating the contents
> of a layer as separate calls.

If I recall correctly, a good reason to have all the data at once
before starting to encode it was the indexing of values.

That is, attribute _values_ can be put in a dictionary and only
referenced per-feature (think of a palette for graphics).
Such "dictionary" can help in case of large repeated values.

Using a row-by-row approach, makes it impossible to build such
dictionary, which is why my early attemps were just at producing
the geometric part, very much like the GML output works, delegating
composition of the whole final product to the caller (which could
eventually also be a ROW-taking wrapper).

--strk;



More information about the postgis-devel mailing list