Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an endpoint to allow runtime configuration, e.g. to updates styles #951

Open
gewesp opened this issue Aug 11, 2023 · 3 comments
Open

Comments

@gewesp
Copy link

gewesp commented Aug 11, 2023

We'd love to use maptiler-gl in our project for vector -> raster rendering, however we need dynamic styles set by the client.

Are there any plans to add that? Would a PR be considered by the maintainer(s)?

@acalcutt
Copy link
Collaborator

acalcutt commented Aug 11, 2023

I'd consider a PR but how would you do that? would you be trying to pass a url to a style or trying to upload styles people create to the style folder? I'm not 100% sure tileserver is the place to do this.

You could easily make an application that points to any style now, as long as the style sets the sources to point to the external tileserver-gl data endpoint urls. In development I often just throw a style on my web server with a html page.

@gewesp
Copy link
Author

gewesp commented Aug 17, 2023

Depends a bit on the size of the style. At the moment, they're quite simple so could even go into URL parameters. Second choice would be to implement a POST request to change the configuration. Third choice to point to an external URL, given the hassle to set up a separate server for that.

My understanding is that tileserver-gl does vector -> raster rendering, which requires a style, right? If not tileserver-gl, what would be "the right place to do this"?

We need to set e.g. the color of individual layers / feature classes, render order etc..

@mjj203
Copy link

mjj203 commented Oct 18, 2023

You could probably get an idea of how to do it from Fresco, which lets you upload a style.json to start editing. https://github.com/go-spatial/fresco

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants