2016-02-17 61 views
0

https://www.mapbox.com/mapbox-gl-style-spec/#sources-raster衛星瓷磚源不工作

這導致黑色瓷磚沒有錯誤信息,我不知道爲什麼?

var style = { 
      "version": 8, 
      "sprite": "mapbox://sprites/mapbox/bright-v8", 
      "glyphs": "mapbox://fonts/mapbox/{fontstack}/{range}.pbf", 
      "sources": { 
       "mapbox-satellite": { 
        "type": "raster", 
        "url": "mapbox://mapbox.satellite", 
        "tileSize": 256 
       } 
      }, 
      "layers": [{ 
       "id": "new-layer", 
       "type": "background", 
       "paint": {"background-color": "#111"}, 
       "interactive": true 
      }], 
     } 

mapboxgl.accessToken = ... 
var map = new mapboxgl.Map({ 
    container: 'map', 
    style: style, 
    //style: 'mapbox://styles/mapbox/satellite-v8', 
    center: [4.7095, 52.0393], 
    zoom: 9, 
    hash: true 
}); 

回答