Tangram: WebGL Maps for Vector Data
The current version of Tangram can be included in your page with:
The library includes a Leaflet plugin,
Tangram.LeafletLayer, to provide basic web map pan/zoom functionality.
Data sources, layers, and styling rules are written in a scene file (here's an example). Armed with a scene file like
scene.yaml, you can create a Tangram scene and add it to a Leaflet map like so:
var map = L;var layer = Tangram;layer;
Read on for more info, or see the documentation.
simple-demo - A minimal demo showing the basic setup
highways-demo - Zoom-dependent styles and contextual filtering rules
gui-demo - Control styles in real-time with a gui
shaders-demo - Simple glsl shaders
Tangram-sandbox - More complex glsl shaders
More examples are available on our documentation's Demos page.
Instead of loading traditional bitmap tiles, Tangram draws its own tiles from scratch, based on vector tiles that contain the source data.
Mapzen provides a free vector tile service based on open data from OpenStreetMap, Natural Earth, Who's On First and other projects, with worldwide coverage updated continuously -- sign up for an API key here.
The scene file is where you specify data sources and layers, filter the data, and define and apply styles. (In our demos, this file is named scene.yaml.) The rules for doing these things are many and various, but the basics are pretty easy, and they are all meticulously documented in the Tangram Documentation.
For technical reference and concept overviews, see the Tangram Documentation.
For questions, comments, suggestions, or to report a bug, please open a new issue.
You can also find us in the Tangram-chat gitter room: https://gitter.im/tangrams/tangram-chat
Tangram JS is officially supported and tested on the last two versions of these browsers:
- Mac OS: Chrome, Firefox, and Safari
- Windows: Chrome, Firefox, IE11, and Edge
- iOS: Safari
- Android: Chrome
Tangram JS should also run in any browser with WebGL support.
Tangram is open-source, and we eagerly welcome feedback, feature requests, and contributions. We’re especially interested to see your maps, no matter how simple! Send screenshots, links, and any questions to firstname.lastname@example.org.
For instructions, see CONTRIBUTING.md.
Tangram is an open-source project sponsored by Mapzen.