![PyPI Now Supports iOS and Android Wheels for Mobile Python Development](https://cdn.sanity.io/images/cgdhsj6q/production/96416c872705517a6a65ad9646ce3e7caef623a0-1024x1024.webp?w=400&fit=max&auto=format)
Security News
PyPI Now Supports iOS and Android Wheels for Mobile Python Development
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Tangram is a JavaScript library for rendering 2D & 3D maps live in a web browser with WebGL. It is tuned for OpenStreetMap but supports any source of GeoJSON/TopoJSON or binary vector data, including tilesets and single files.
Here's a simple demo (repo here) with a basic example of a Tangram map.
Tangram is instantiated as a Leaflet plugin for integration with standard web maps. Tangram-ES is a native mobile version of the Tangram library, written in C++.
The current version of Tangram can be included in your page with:
<script src="https://mapzen.com/tangram/tangram.min.js"></script>
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.map('map');
var layer = Tangram.leafletLayer({ scene: 'scene.yaml' });
layer.addTo(map);
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.
Tangram currently supports GeoJSON & TopoJSON-based tiles, as well as Mapbox's binary format, all of which are available from the Mapzen vector tile service. (Here's an example GeoJSON tile.)
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.
The scene file is written in YAML, which is a data-serialization format like JSON, but with less punctuation. Instead, data structures are specified with whitespace, like Python. One neat side benefit is that the format is super friendly to strings, which means you can write inline JavaScript and GLSL code straight into the scene file, without needing to wrap it in quotes or concatenate anything.
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 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 tangram@mapzen.com.
For instructions, see CONTRIBUTING.md.
Tangram is an open-source project sponsored by Mapzen.
FAQs
WebGL Maps for Vector Tiles
The npm package tangram receives a total of 114 weekly downloads. As such, tangram popularity was classified as not popular.
We found that tangram demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.