From 24b0b99f7125880bdee544caec0bd68d372050ab Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Thu, 07 Dec 2023 16:17:51 +0800
Subject: [PATCH] 更换底图
---
src/store/modules/openlayerData.js | 42 ++----------------------------------------
1 files changed, 2 insertions(+), 40 deletions(-)
diff --git a/src/store/modules/openlayerData.js b/src/store/modules/openlayerData.js
index 292dc53..a6bf70a 100644
--- a/src/store/modules/openlayerData.js
+++ b/src/store/modules/openlayerData.js
@@ -42,32 +42,6 @@
import TilegridTileGrid from "ol/tilegrid/TileGrid";
-const tileUrl =
- "https://fkxt.jxstnu.edu.cn/changjing/arcgis/rest/services/ksd1/MapServer/tile/{z}/{y}/{x}";
-// 坐标原点
-const origin = [-400.0, 399.9999999999998];
-// 分辨率
-const resolutions = [
- 0.00019035688046642243, 0.00014276766034981682, 0.00009517844023321122,
- 0.00004758922011660561,
-];
-const fullExtent = [
- 112.51302281804038, -0.17416638494176828, 112.76131189483516,
- 0.000004509395743004334,
-];
-const tileGrid = new TilegridTileGrid({
- tileSize: 256,
- origin: origin,
- extent: fullExtent,
- resolutions: resolutions,
-});
-// 瓦片数据源
-const tileArcGISXYZ = new XYZ({
- tileGrid: tileGrid,
- projection: "EPSG:4326",
- url: tileUrl,
-});
-
const openlayerData = {
state: {
mapscene: {
@@ -75,20 +49,8 @@
},
openlayers: {
map2D: new OlMap({
- layers: [
- // 瓦片图层
- // new OlLayerTile({
- // source: tileArcGISXYZ,
- // }),
- ],
- view: new OlView({
- // 初始化中心点坐标
- // center: [112.63716735643777, -0.087080937773012637833],
- // 注意:此处指定缩放级别不能通过zoom来指定,指定了也无效,必须通过resolution来指定
- // resolution: 0.00014276766034981682,
- projection: "EPSG:4326",
- // extent: fullExtent,
- }),
+ layers: [],
+ view: new OlView({}),
}),
map3D: null,
--
Gitblit v1.9.3