Toggle navigation
layers中上面的图层会挡住下面的图层导致无法选中下面图层中的物体
By
techzealot
2018-04-20 16:41:28
脚本
16
21
作品使用的第三方脚本
http://echarts.baidu.com/resource/echarts-gl-latest/dist/echarts-gl.min.js,/dep/echarts/map/js/world.js
数据管理
上传数据
支持小于 5M 任意格式(csv, xlsx, json, xml, ...)的数据文件
上传后可以通过生成的文件链接异步获取托管的数据。
历史数据
0 条
无历史数据
代码修改记录
信息提示
保存作品
对当前截图不满意?你还可以
上传本地截图
重新截图
作品名称
作品描述
标签
geo
grid
legend
markLine
markPoint
bar
effectScatter
line
lines
map
timeline
title
toolbox
tooltip
visualMap
作品默认版本
最新
16
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
20:11:45
图表已生成
整理代码
刷新
代码
var baseTexture = "/asset/get/s/data-1524241630540-ryDJS5P2f.jpg"; var clouds = "/asset/get/s/data-1524241644720-H1rlB5Pnz.png"; var heightTexture = "/asset/get/s/data-1524241653833-S1CgS5vnM.jpg"; //创建canvas贴图 var canvas = document.createElement('canvas'); var mapChart = echarts.init(canvas, null, { width: 2048, height: 1024 }); mapChart.setOption({ geo: { type: 'map', map: 'world', top: 0, left: 0, right: 0, bottom: 0, boundingCoords: [ [-180, 90], [180, -90] ], itemStyle: { normal: { areaColor: 'transparent', borderColor: '#121212' }, emphasis: { areaColor: 'yellow' } }, selectedMode: 'single' } }); var option = { backgroundColor: '#000', globe: { //基本贴图 baseTexture: baseTexture, //高度纹理贴图 heightTexture: heightTexture, //地球顶点位移的大小 displacementScale: 0.5, //地球顶点位移的质量 displacementQuality: 'high', //使用渐变色作为环境色 environment: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{ offset: 0, color: '#00aaff' // 天空颜色 }, { offset: 0.7, color: '#998866' // 地面颜色 }, { offset: 1, color: '#998866' // 地面颜色 }], false), //地球中三维图形的着色效果 shading: 'lambert', //color,lambert,realistic light: { ambient: { intensity: 0.6 }, main: { intensity: 1.0 } }, layers: [ //echarts 4 中type不能为blend,是bug { type: 'blend', texture: mapChart, shading: 'lambert', }, //上面的层会挡住下面的层导致无法选中 { type: 'overlay', texture: clouds, shading: 'lambert', distance: 5 }, ], }, series: [ ] }