cesium icon indicating copy to clipboard operation
cesium copied to clipboard

Vector Tiles

Open pjcozzi opened this issue 11 years ago • 60 comments

2D maps like Google, Apple, MapBox GL, and OL3 are moving to actual vectors for rendering vector data, instead of baking vector data into a raster tile. This allows, for example, to make labels always face up even if south is up and to fade out labels so they never hit each other.

For now, this roadmap is a collection of resources on this topic.

pjcozzi avatar Sep 16 '14 18:09 pjcozzi

Vector tiles for fast custom maps (video) , http://vimeo.com/10622814 Wrong video ? :)

pksorensen avatar Dec 07 '14 13:12 pksorensen

Fixed. Thanks.

pjcozzi avatar Dec 08 '14 16:12 pjcozzi

More discussion: https://groups.google.com/forum/#!topic/cesium-dev/QnOxsA0iwa0

pjcozzi avatar Feb 16 '15 22:02 pjcozzi

Looks like ESRI is adopting Mapbox vector tiles: https://www.mapbox.com/blog/vector-tile-adoption/

mramato avatar Mar 17 '15 20:03 mramato

Info from FOSS4G NA 2015.

pjcozzi avatar Mar 19 '15 11:03 pjcozzi

pjcozzi avatar Jun 20 '15 15:06 pjcozzi

http://osgeo-org.1560.x6.nabble.com/Asking-for-new-vector-tiles-community-module-tt5211994.html

pjcozzi avatar Jun 22 '15 21:06 pjcozzi

  • From Esri: http://blogs.esri.com/esri/arcgis/2015/07/20/vector-tiles-preview/

pjcozzi avatar Jul 20 '15 21:07 pjcozzi

Demo of vector tiles at Esri UC is last video on page

http://www10.giscafe.com/blogs/gissanjay/2015/07/20/keynote-from-jack-dangermond-at-the-2015-esri-user-conference/

From: Patrick Cozzi [mailto:[email protected]] Sent: Monday, July 20, 2015 5:45 PM To: AnalyticalGraphicsInc/cesium Subject: Re: [cesium] Vector Tiles (#2132)

  • From Esri: http://blogs.esri.com/esri/arcgis/2015/07/20/vector-tiles-preview/

— Reply to this email directly or view it on GitHubhttps://github.com/AnalyticalGraphicsInc/cesium/issues/2132#issuecomment-123053536.

GatorScott avatar Jul 22 '15 12:07 GatorScott

Is this still being considered by Cesium? It would be an impressive feature to tout.

bensleveritt avatar Oct 19 '16 06:10 bensleveritt

Yes, but our current focus is on 3D Tiles.

pjcozzi avatar Oct 19 '16 12:10 pjcozzi

Hello, I want to know when will it come out, I'm very looking forward to it~

bingqixuan avatar Jul 31 '17 02:07 bingqixuan

Current work-in-progress for 3D Tiles vector tiles is in the vector-tiles branch. The final date is still TBA.

pjcozzi avatar Jul 31 '17 02:07 pjcozzi

@pjcozzi Was this issue "fixed" with https://github.com/AnalyticalGraphicsInc/cesium/pull/6097?

davidyaha avatar Jun 03 '18 09:06 davidyaha

@davidyaha that added support for the draft vector tile payload in 3D Tiles, but I would still leave this issue open for other potential vector tile specs.

pjcozzi avatar Jun 07 '18 16:06 pjcozzi

OSM has global vector data, it would be cool to support that in Cesium and eventually serve it from ion:

https://openmaptiles.com/downloads/dataset/osm/#0.23/0/-26

Forum discussion.

OmarShehata avatar Oct 11 '18 15:10 OmarShehata

Requested again here: https://github.com/AnalyticalGraphicsInc/cesium/issues/7939

Also perhaps relevant, some thoughts on how TerriaJS loads these vector tiles? https://github.com/AnalyticalGraphicsInc/cesium/issues/6182#issuecomment-362723885

OmarShehata avatar Jun 14 '19 07:06 OmarShehata

Is there any related work or PR that we could follow up?

bampakoa avatar Jul 02 '19 14:07 bampakoa

How can I extend MapboxImageryProvider to load PBF files instead PNG ? I think I can do something to put it to work using this : https://landtechnologies.github.io/Mapbox-vector-tiles-basic-js-renderer/.

As I can see, this renderer can get a PBF from {x},{y},{z} and render it in any canvas (the Cesium canvas??).

https://landtechnologies.github.io/Mapbox-vector-tiles-basic-js-renderer/debug/basic/google

it is just an idea to start. I know almost nothing about how Providers work. I need to know how to test a new Provider without need to compile all Cesium code. Any way to add it as a plugin? Some code to show me how?

What do you say?

icemagno avatar Jan 29 '20 18:01 icemagno

@icemagno you might find the GridImageryProvider useful as a reference here. It's the simplest imagery provider I know of (procedural creates a grid as the tiles): https://github.com/AnalyticalGraphicsInc/cesium/blob/master/Source/Scene/GridImageryProvider.js

It should be straightforward to set up the CesiumJS source code so you can add your custom class, see the build guide here: https://github.com/AnalyticalGraphicsInc/cesium/blob/master/Documentation/Contributors/BuildGuide/README.md#build-guide

OmarShehata avatar Jan 29 '20 18:01 OmarShehata

Ok. I'll give a try. BTW: I know you guys have a long expertise to write thousands of lines before build and test but I like to check every step I do in the code.

So... I dont like the "write-build-test" method because I'll spend hours in a lot of builds. Is there some "write-F5-test" way to do this? I mean... can I write my code and immediately check it just refreshing the browser without the need to rebuild every time?

icemagno avatar Jan 29 '20 19:01 icemagno

BTW: I know you guys have a long expertise to write thousands of lines before build and test

I don't think that's a good idea no matter how much expertise anyone has :smile:

When running CesiumJS from the source as described in the linked guide above, you can make changes directly to the source and see the changes immediately by refreshing the page or re-running the Sandcastle example. This is how most CesiumJS development is done.

If you have any follow up questions on best practices here, let's take this conversation to the forum so as not to derail this GitHub issue.

OmarShehata avatar Jan 29 '20 19:01 OmarShehata

How can I extend MapboxImageryProvider to load PBF files instead PNG ? I think I can do something to put it to work using this : https://landtechnologies.github.io/Mapbox-vector-tiles-basic-js-renderer/.

As I can see, this renderer can get a PBF from {x},{y},{z} and render it in any canvas (the Cesium canvas??).

https://landtechnologies.github.io/Mapbox-vector-tiles-basic-js-renderer/debug/basic/google

it is just an idea to start. I know almost nothing about how Providers work. I need to know how to test a new Provider without need to compile all Cesium code. Any way to add it as a plugin? Some code to show me how?

What do you say?

@icemagno What if we suse something like this library https://github.com/Leaflet/Leaflet.VectorGrid

am2222 avatar Mar 10 '20 19:03 am2222

@am2222 I'm using Cesium not Leaflet

icemagno avatar Mar 10 '20 22:03 icemagno

@icemagno yeah I know, I am also looking for a way to make vector tiles work on cesium, but that plugin actually is doing the same thing as you said.it reads pbf files draws them on a canvas and leaflet plots that canvas. in our case we need draw pbf using cesium's canvas.

am2222 avatar Mar 10 '20 23:03 am2222

Terriajs has a MapboxVectorTileImageryProvider which draws (polygons only at this point in time) to canvas - see https://github.com/TerriaJS/terriajs/blob/master/lib/Map/MapboxVectorTileImageryProvider.js @steve9164 created this a few years ago, he can give you more info about it

nf-s avatar Mar 11 '20 01:03 nf-s

@nf-s I think the provided sample helps me alot. I have not looked at it in details yet, Does it use any internal files fron terriajs library as well?

am2222 avatar Mar 11 '20 02:03 am2222

It uses 2 small utility functions from the terria library which are essential, but everything else is imported from Cesium, @mapbox/vector-tile, pbf and urijs (except the i18next internationalisation stuff which can be stripped out)

nf-s avatar Mar 11 '20 02:03 nf-s