简体   繁体   English

如何用半透明覆盖覆盖 MapBox 地图?

[英]How do you cover a MapBox map with a semi-transparent overlay?

I would like to put an opacity: 0.7 layer over the whole map, but in between the geography tiles and some dots I'm going to draw at specific lat/lngs.我想在整个地图上放置一个opacity: 0.7 ,但在地理图块和一些点之间,我将在特定的纬度/经度处绘制。 How can I add a semi-transparent overlay to a MapBox map in between my dots and the land/water?如何在点和陆地/水域之间的 MapBox 地图中添加半透明叠加层?

Here is the sample code from the mapbox-gl lib https://docs.mapbox.com/mapbox-gl-js/example/adjust-layer-opacity/这是来自 mapbox-gl 库的示例代码https://docs.mapbox.com/mapbox-gl-js/example/adjust-layer-opacity/

Its basically a part of the style specification, where you need to create a layer on map styles它基本上是样式规范的一部分,您需要在地图样式上创建一个图层

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM