The Shapes class draws 3 dimensional shapes on top of a map. The shapes are created using GeoJSON geometry, which could be a Polygon, MultiPolygon (array of polygons) or a LineString.
This class is accessed using MapView.Shapes.
Refer to the Shapes Guide for more information and interactive examples.
Adds a custom GeoJSON geometry (Shape) to the map.
a valid GeoJSON feature collection
Optional
Floor to add the geometry to
The created shapes, or undefined if creation failed.
map.Shapes.add(polygons, { color: 'red' }, mapView.currentFloor); Copy
map.Shapes.add(polygons, { color: 'red' }, mapView.currentFloor);
Removes a specific shape (Shape) from the map.
The shape to be removed.
map.Shapes.remove(geo); Copy
map.Shapes.remove(geo);
Removes all Shapes (Shape) from the map.
map.Shapes.removeAll(); Copy
map.Shapes.removeAll();
The Shapes class draws 3 dimensional shapes on top of a map. The shapes are created using GeoJSON geometry, which could be a Polygon, MultiPolygon (array of polygons) or a LineString.
This class is accessed using MapView.Shapes.
Refer to the Shapes Guide for more information and interactive examples.