Skip to content

Commit b3b5dce

Browse files
[fix]mapboxgl l7支持多坐标系,listLayers图层顺序 review by qiw
1 parent 1016f0a commit b3b5dce

95 files changed

Lines changed: 783 additions & 500 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎build/webpack.config.base.js‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,6 @@ module.exports = {
6565
echarts: 'function(){try{return echarts}catch(e){return {}}}()',
6666
mapv: 'function(){try{return mapv}catch(e){return {}}}()',
6767
'@antv/g6': 'function(){try{return G6}catch(e){return {}}}()',
68-
'@antv/l7': 'function(){try{return L7}catch(e){return {}}}()',
69-
'@antv/l7-three': 'function(){try{return window}catch(e){return {}}}()',
7068
'@tensorflow/tfjs': 'function(){try{return tf}catch(e){return {}}}()'
7169
},
7270

‎build/webpack.config.mapboxgl.js‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ module.exports = {
2929
'webgl-debug': '(function(){try{return webgl-debug}catch(e){return {}}})()',
3030
xlsx: 'function(){try{return XLSX}catch(e){return {}}}()',
3131
canvg: 'function(){try{return canvg}catch(e){return {}}}()',
32-
jsonsql: 'function(){try{return jsonsql}catch(e){return {}}}()'
32+
jsonsql: 'function(){try{return jsonsql}catch(e){return {}}}()',
33+
'@supermap/mapboxgl-l7-render': 'function(){try{return L7}catch(e){return {}}}()'
3334
})
3435
],
3536

‎build/webpack.config.maplibregl.js‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ module.exports = {
2929
xlsx: 'function(){try{return XLSX}catch(e){return {}}}()',
3030
canvg: 'function(){try{return canvg}catch(e){return {}}}()',
3131
jsonsql: 'function(){try{return jsonsql}catch(e){return {}}}()',
32-
'xml-js': 'function(){try{return convert}catch(e){return {}}}()'
32+
'xml-js': 'function(){try{return convert}catch(e){return {}}}()',
33+
'@supermap/maplibregl-l7-render': 'function(){try{return L7}catch(e){return {}}}()'
3334
}),
3435

3536
module: {

‎dist/mapboxgl/include-mapboxgl.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
inputScript(libsurl + '/mapbox-gl-js-enhance/1.12.1-3/mapbox-gl-enhance.js');
6464
}
6565
if (inArray(includes, 'L7')) {
66-
inputScript(disturl + '/mapboxgl/l7-dev.js');
66+
inputScript(libsurl+ '/mapboxgl-l7-render/index.js');
6767
}
6868
if (inArray(includes, 'g2')) {
6969
inputScript('https://cdnjs.cloudflare.com/ajax/libs/antv-g2/4.2.8/g2.min.js');

‎dist/maplibregl/include-maplibregl.js‎

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -54,23 +54,15 @@
5454
var includes = (targetScript.getAttribute('include') || '').split(',');
5555
var excludes = (targetScript.getAttribute('exclude') || '').split(',');
5656
if (!inArray(excludes, 'maplibregl')) {
57-
// inputCSS(libsurl + '/maplibre-gl-js/3.1.0/maplibre-gl.css');
58-
// inputScript(libsurl + '/maplibre-gl-js/3.1.0/maplibre-gl.js');
59-
inputCSS('https://unpkg.com/maplibre-gl@2.4.0/dist/maplibre-gl.css');
60-
inputScript('https://unpkg.com/maplibre-gl@2.4.0/dist/maplibre-gl.js');
57+
inputCSS(libsurl + '/maplibre-gl-js/3.1.0/maplibre-gl.css');
58+
inputScript(libsurl + '/maplibre-gl-js/3.1.0/maplibre-gl.js');
6159
}
6260
if (inArray(includes, 'L7')) {
63-
inputScript('../../dist/maplibregl/l7-dev.js');
61+
inputScript(libsurl + '/maplibregl-l7-render/index.js');
6462
}
6563
if (inArray(includes, 'g2')) {
6664
inputScript('https://cdnjs.cloudflare.com/ajax/libs/antv-g2/4.2.8/g2.min.js');
6765
}
68-
if (inArray(includes, 'L7Three')) {
69-
// inputScript('https://cdnjs.cloudflare.com/ajax/libs/three.js/r115/three.min.js');
70-
inputScript(libsurl + '/three/0.115.0/three.min.js');
71-
inputScript(libsurl + '/three/0.115.0/examples/js/loaders/GLTFLoader.js');
72-
inputScript('../../dist/maplibregl/l7-three.min.js');
73-
}
7466
if (inArray(includes, 'turf')) {
7567
inputScript(libsurl + '/turf/6.5.0/turf.min.js');
7668
}

‎examples/mapboxgl/config.js‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1249,7 +1249,7 @@ var exampleConfig = {
12491249
L7: {
12501250
name: 'L7',
12511251
name_en: 'L7',
1252-
version: '11.1.1',
1252+
version: '11.2.0',
12531253
content: [
12541254
{
12551255
name: '网格地图',
@@ -1623,12 +1623,12 @@ var exampleConfig = {
16231623
thumbnail: 'l7_heatmap_hexagon3.png',
16241624
fileName: 'l7_heatmap_hexagon3'
16251625
},
1626-
{
1627-
name: '平面图层',
1628-
name_en: 'Flat layer',
1629-
thumbnail: 'l7_flat_layer.png',
1630-
fileName: 'l7_flat_layer'
1631-
},
1626+
// {
1627+
// name: '平面图层',
1628+
// name_en: 'Flat layer',
1629+
// thumbnail: 'l7_flat_layer.png',
1630+
// fileName: 'l7_flat_layer'
1631+
// },
16321632
// {
16331633
// name: '自定义3D地形(LOD)',
16341634
// name_en: 'Customize 3D Terrain (LOD)',

‎examples/mapboxgl/demo-l7layer.html‎

Lines changed: 0 additions & 92 deletions
This file was deleted.

‎examples/mapboxgl/l7_3d_column.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929

3030
<body>
3131
<div id="map"></div>
32-
<script type="text/javascript" include="L7" src="../../dist/mapboxgl/include-mapboxgl.js"></script>
32+
<script type="text/javascript" include="mapbox-gl-enhance,L7" src="../../dist/mapboxgl/include-mapboxgl.js"></script>
3333
<script type="text/javascript">
3434
var host = window.isLocal ? window.server : 'https://iserver.supermap.io';
3535
var attribution =

‎examples/mapboxgl/l7_3d_geometry.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929

3030
<body>
3131
<div id="map"></div>
32-
<script type="text/javascript" include="L7" src="../../dist/mapboxgl/include-mapboxgl.js"></script>
32+
<script type="text/javascript" include="mapbox-gl-enhance,L7" src="../../dist/mapboxgl/include-mapboxgl.js"></script>
3333
<script type="text/javascript">
3434
var host = window.isLocal ? window.server : 'https://iserver.supermap.io';
3535
var attribution =

‎examples/mapboxgl/l7_3d_honeycomb.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929

3030
<body>
3131
<div id="map"></div>
32-
<script type="text/javascript" include="L7" src="../../dist/mapboxgl/include-mapboxgl.js"></script>
32+
<script type="text/javascript" include="mapbox-gl-enhance,L7" src="../../dist/mapboxgl/include-mapboxgl.js"></script>
3333
<script type="text/javascript">
3434
var host = window.isLocal ? window.server : 'https://iserver.supermap.io';
3535
var attribution =

0 commit comments

Comments
 (0)