Closed jerryhall closed 7 years ago
Geobuf is designed for lossless encoding of geojson. Given that tangram will be reading tiles, existing binary formats like mvt seem to make more sense, or topojson.
Thanks @pnorman. My interest, which I should have made more clear, is in large file sizes of points of interest. My file size is typically 20+MB, which if I could cut down to 1MB or less that would be great. I understand topojson and mvt to be more for polygons no? Thanks again.
mvt can store points. The big difference is going to be tiling vs not. geojson to geobuf has about a 2.5:1 compression ratio (when transferred with http and gzip encoding), so if you have files that big, you'll want to tile with either, and when using tiled data, mvt is an option already.
For only points, topojson doesn't offer any real advantages afaik.
Ok cool. Thanks @pnorman
I discovered this code to reduce GeoJSON to about 3% of original size (in a use-case I learned about locally from 180mb to less than 2mb) . Could you tell me if this is usable with Tangram? My load times aren't too painful but, this kind of speed boost is significant and would be appreciated by users I'm sure.
https://github.com/mapbox/geobuf
Thanks!