@kq_npm/client3d_webgl_vue 4.5.55 → 4.5.57

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/adddata/index.js +189 -21
  2. package/airspacegridoccupancyquery/index.js +1977 -0
  3. package/airspacegridoccupancyquery/style/airspacegridoccupancyquery.css +1 -0
  4. package/airspacegridoccupancyquery/style/index.js +3 -0
  5. package/airspaceprofileanalysis/index.js +1870 -0
  6. package/airspaceprofileanalysis/style/airspaceprofileanalysis.css +1 -0
  7. package/airspaceprofileanalysis/style/index.js +3 -0
  8. package/aspectanalysis/index.js +25 -7
  9. package/baseterraingallery/index.js +16 -4
  10. package/boxclip/index.js +58 -16
  11. package/buildpointmodel/index.js +3207 -230
  12. package/buildpointmodel/style/buildpointmodel.css +1 -1
  13. package/buildpolygonmodel/index.js +205 -81
  14. package/buildpolylinemodel/index.js +346 -70
  15. package/clientPrint/index.js +32440 -2337
  16. package/comparemap/index.js +132 -60
  17. package/compass/index.js +16 -6
  18. package/excavatefillanalysis/index.js +51 -7
  19. package/fixedzoomin/index.js +24 -7
  20. package/fixedzoomout/index.js +25 -7
  21. package/flight/index.js +113 -26
  22. package/floodanalysis/index.js +79 -14
  23. package/geologicalbodyanalysis/index.js +41 -5
  24. package/gpuspatialquery/index.js +127 -19
  25. package/gridoccupancyquery/index.js +627 -0
  26. package/gridoccupancyquery/style/gridoccupancyquery.css +1 -0
  27. package/gridoccupancyquery/style/index.js +3 -0
  28. package/hawkeye/index.js +20 -2
  29. package/headertemp/index.js +7 -2
  30. package/heatmap3d/index.js +282 -158
  31. package/index.js +32440 -2337
  32. package/isolineanalysis/index.js +113 -38
  33. package/light/index.js +80 -22
  34. package/limitheightanalysis/index.js +30 -10
  35. package/lowaltitudefeature/index.js +5027 -0
  36. package/lowaltitudefeature/style/index.js +3 -0
  37. package/lowaltitudefeature/style/lowaltitudefeature.css +1 -0
  38. package/measure/index.js +60 -19
  39. package/modelFlat/index.js +48 -8
  40. package/modeledit/index.js +38 -4
  41. package/modelexcavate/index.js +48 -7
  42. package/modelfilter/index.js +51 -8
  43. package/modelmaterialedit/index.js +127 -25
  44. package/modelprofileanalysis/index.js +51 -14
  45. package/modelselect/index.js +34 -3
  46. package/modelstyleedit/index.js +39 -3
  47. package/modeltransform/index.js +79 -14
  48. package/package.json +1 -1
  49. package/particleeffect/index.js +83 -17
  50. package/planeclip/index.js +66 -17
  51. package/pointcloudrender/index.js +134 -15
  52. package/radarscananalysis/index.js +35 -3
  53. package/resetview/index.js +14 -6
  54. package/roller/index.js +55 -18
  55. package/scaneffect/index.js +98 -29
  56. package/sceneadvancedtoimage/index.js +32 -6
  57. package/sceneapp/index.js +32440 -2337
  58. package/sceneset/index.js +141 -71
  59. package/scenetohdimage/index.js +23 -3
  60. package/sceneview/index.js +32440 -2337
  61. package/sceneview/style/sceneview.css +1 -1
  62. package/screenshot/index.js +44 -11
  63. package/shadowanalysis/index.js +79 -19
  64. package/sightlineanalysis/index.js +66 -15
  65. package/skylineanalysis/index.js +20 -4
  66. package/slopeanalysis/index.js +75 -16
  67. package/slopeaspectanalysis/index.js +128 -26
  68. package/statusbar/index.js +80 -67
  69. package/style.css +1 -1
  70. package/terrainoperation/index.js +39 -7
  71. package/terrainprofileanalysis/index.js +43 -5
  72. package/toolbarapp/index.js +32440 -2337
  73. package/toolboxapp/index.js +32440 -2337
  74. package/typhoontrac/index.js +134 -16
  75. package/underground/index.js +8 -2
  76. package/videofusion/index.js +164 -79
  77. package/videoproject/index.js +77 -23
  78. package/viewshedanalysis/index.js +61 -14
  79. package/weathereffect/index.js +73 -18
  80. package/webgl.es.js +866 -16
  81. package/windyslicing/index.js +258 -54
  82. package/wireframesketch/index.js +25 -8
@@ -102,11 +102,17 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
102
102
  lang,
103
103
  locale
104
104
  } = (0, _useGlobalConfig.useLocale)();
105
+ // 台风轨迹逻辑类
105
106
  let viewModel = null;
107
+ // 台风轨迹容器Ref
106
108
  let ref_box = (0, _vue.ref)();
109
+ // 当前选中台风行
107
110
  let currentRow = (0, _vue.ref)({});
111
+ // 当前播放台风行
108
112
  let currentPlay = (0, _vue.ref)({});
113
+ // 是否显示详情
109
114
  let showInfo = (0, _vue.ref)(false);
115
+ // 加载状态
110
116
  let loading = (0, _vue.ref)(false);
111
117
  // 获取组件传参
112
118
  const props = __props;
@@ -115,6 +121,7 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
115
121
 
116
122
  // 生成组件默认header
117
123
  let headerTemp = (0, _vue.ref)();
124
+ // header组件Ref
118
125
  let headerTempRef = (0, _vue.ref)();
119
126
  // 属性值
120
127
  let tableData = (0, _vue.ref)([]);
@@ -135,6 +142,8 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
135
142
  // 是否显示离线数据功能
136
143
  typhoonTracPath: props.settingParams?.typhoonTracPath ?? "" // 离线数据文件路径
137
144
  });
145
+
146
+ // 台风强度类型图例
138
147
  const strongType = [{
139
148
  name: t('webgl.tropicalPressure'),
140
149
  color: "#08F6A0, #00CF63"
@@ -154,6 +163,7 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
154
163
  name: t('webgl.superTyphoon'),
155
164
  color: "#FF636F, #FF0016"
156
165
  }];
166
+ // 台风路径线型图例(各国机构)
157
167
  const lineList = [{
158
168
  name: t('webgl.chinaTitle'),
159
169
  color: "#ff3c4e"
@@ -191,6 +201,7 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
191
201
  viewModel = new _TyphoonTracViewModel.default(scenceView);
192
202
  viewModel._language = locale;
193
203
  formItem.typhoonTracPath && getDataByPath();
204
+ // 存在外部接口时通过接口获取台风列表
194
205
  if (props.getTyphoonTracListByApi) {
195
206
  loading.value = true;
196
207
  props.getTyphoonTracListByApi(data => {
@@ -225,7 +236,10 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
225
236
  clear();
226
237
  }
227
238
  }
228
- // 选择文件
239
+ /**
240
+ * @description 选择文件
241
+ * @param {Object} file 文件对象
242
+ */
229
243
  function selectData(file) {
230
244
  let url = URL.createObjectURL(file.raw);
231
245
  formItem.typhoonTracPath = url;
@@ -234,15 +248,25 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
234
248
  currentPlay.value = {};
235
249
  formItem.collapseValue = "list";
236
250
  }
251
+ /**
252
+ * @description 表格时间列格式化
253
+ * @param {Object} row 行数据
254
+ * @returns {String} 格式化后的时间
255
+ */
237
256
  function formatterFun(row) {
238
257
  return formatDate(row.time);
239
258
  }
240
- // 显示台风
259
+ /**
260
+ * @description 显示/隐藏台风
261
+ * @param {Number} index 行索引
262
+ * @param {Object} row 行数据
263
+ */
241
264
  async function showTyphoon(index, row) {
242
265
  try {
243
266
  await getDataInfoByApi(row); // 等待回调完成
244
267
  row.show = !row.show;
245
268
  if (!row.show) {
269
+ // 隐藏时清除弹框并停止播放
246
270
  viewModel && viewModel.clearDivPoint(row.tfid);
247
271
  setTracStop(index, row);
248
272
  }
@@ -252,6 +276,11 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
252
276
  // 可以添加错误处理逻辑,例如显示错误提示
253
277
  }
254
278
  }
279
+ /**
280
+ * @description 设置台风详情信息
281
+ * @param {Number} index 行索引
282
+ * @param {Object} row 行数据
283
+ */
255
284
  async function setDatainfo(index, row) {
256
285
  try {
257
286
  await getDataInfoByApi(row);
@@ -264,6 +293,12 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
264
293
  // 可以添加错误处理逻辑,例如显示错误提示
265
294
  }
266
295
  }
296
+
297
+ /**
298
+ * @description 通过外部接口获取台风详情数据
299
+ * @param {Object} row 台风行数据
300
+ * @returns {Promise} Promise对象
301
+ */
267
302
  async function getDataInfoByApi(row) {
268
303
  // 条件判断提前返回
269
304
  if (!props.getDataInfoByApi || row.getInfoVis) {
@@ -312,6 +347,10 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
312
347
  };
313
348
  return dateFormats.MM + "-" + dateFormats.DD + " " + dateFormats.hh + "时";
314
349
  }
350
+ /**
351
+ * @description 表格单元格类名回调,给行列索引赋值
352
+ * @param {Object} param0 解构参数(row、column、rowIndex、columnIndex)
353
+ */
315
354
  function tableCellClassName({
316
355
  row,
317
356
  column,
@@ -323,13 +362,21 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
323
362
  row.index = rowIndex;
324
363
  column.index = columnIndex;
325
364
  }
365
+ /**
366
+ * @description 点击路径表格行
367
+ * @param {Object} row 行数据
368
+ */
326
369
  function rowClickPath(row) {
327
370
  viewModel && viewModel.clearDivPoint(currentRow.value.tfid);
328
371
  if (!currentRow.value.show) currentRow.value.show = true;
329
372
  if (currentRow.value.showPlayVis) setTracStop(row.index, currentRow.value);
330
373
  viewModel && viewModel.rowClickPath(row.index, currentRow.value);
331
374
  }
332
- // 播放
375
+ /**
376
+ * @description 播放台风轨迹
377
+ * @param {Number} index 行索引
378
+ * @param {Object} row 行数据
379
+ */
333
380
  async function setTracPlay(index, row) {
334
381
  try {
335
382
  await getDataInfoByApi(row); // 等待回调完成
@@ -342,7 +389,11 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
342
389
  // 可以添加错误处理逻辑,例如显示错误提示
343
390
  }
344
391
  }
345
- // 停止播放
392
+ /**
393
+ * @description 停止播放台风轨迹
394
+ * @param {Number} index 行索引
395
+ * @param {Object} row 行数据
396
+ */
346
397
  function setTracStop(index, row) {
347
398
  row.showPlayVis = false;
348
399
  viewModel && viewModel.stopPlayTyphoonTrac(row);
@@ -352,6 +403,7 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
352
403
  if (formItem && formItem.typhoonTracPath) {
353
404
  Cesium.Resource.fetchJson(formItem.typhoonTracPath).then(res => {
354
405
  if (res) {
406
+ // 数据为空时提示
355
407
  if (res.length === 0) {
356
408
  KqMessage({
357
409
  message: "features " + t('webgl.noDataMessage') + "!",
@@ -373,13 +425,17 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
373
425
  return;
374
426
  }
375
427
  }
376
- // 更新台风数据
428
+ /**
429
+ * @description 更新台风数据
430
+ * @param {Array} data 台风数据数组
431
+ */
377
432
  function setTyphoonTracData(data) {
378
433
  if (data && data.length && data.length > 0) {
379
434
  clear();
380
435
  tableData.value = data;
381
436
  }
382
437
  }
438
+ // 清除
383
439
  function clear() {
384
440
  viewModel && viewModel.clear();
385
441
  }
@@ -686,28 +742,44 @@ exports["default"] = void 0;
686
742
  */
687
743
  // 国际化
688
744
  class TyphoonTracViewModel {
745
+ // 播放事件监听器
746
+ /**
747
+ * @description 台风轨迹逻辑类构造函数
748
+ * @param {Object} scenceView 三维场景视图对象
749
+ */
689
750
  constructor(scenceView) {
690
751
  this._viewer = null;
691
752
  // 三维viewer对象
692
753
  this._language = null;
754
+ // 当前语言对象
693
755
  this._curTyphoon = [];
756
+ // 当前台风对象集合
694
757
  this.currentRow = null;
758
+ // 当前选中台风行
695
759
  this.divPoint = null;
760
+ // 浮动信息弹框
696
761
  this.eventListener = null;
762
+ // 悬停事件监听器
697
763
  this.eventListener2 = null;
698
764
  this._viewer = scenceView._viewer;
699
765
  this._viewer.postProcessStages.fxaa.enabled = true;
700
766
  // 开启深度检测
701
767
  this._viewer.scene.globe.depthTestAgainstTerrain = true;
702
768
  }
703
- // 控制台风显示
769
+ /**
770
+ * @description 控制台风显示
771
+ * @param {Object} row 台风行数据
772
+ * @param {Boolean} play 是否播放
773
+ */
704
774
  createTyphoonPath(row, play = false) {
705
775
  if (!this.warningLine_48) this.createWarningLine();
706
776
  let that = this;
707
777
  if (this._curTyphoon[row.tfid]) {
778
+ // 已存在台风对象则设置可见性
708
779
  this._curTyphoon[row.tfid].setVisible(row.show);
709
780
  row.show && this._curTyphoon[row.tfid].flyTo();
710
781
  } else {
782
+ // 不存在则创建台风对象并绑定事件
711
783
  let res = Object.assign({}, row);
712
784
  this._curTyphoon[row.tfid] = new Cesium.Kq3dTyphoon(this._viewer, {
713
785
  data: res
@@ -752,6 +824,7 @@ class TyphoonTracViewModel {
752
824
  }
753
825
  if (row.show) {
754
826
  if (play) {
827
+ // 播放前停止当前正在播放的台风
755
828
  if (this.currentRow && this.currentRow.tfid && this._curTyphoon[this.currentRow.tfid] && this._curTyphoon[this.currentRow.tfid].stop) {
756
829
  this._curTyphoon[this.currentRow.tfid].stop();
757
830
  }
@@ -760,14 +833,21 @@ class TyphoonTracViewModel {
760
833
  }
761
834
  this.currentRow = row;
762
835
  }
763
- // 获取
836
+ /**
837
+ * @description 获取弹框点数据(解析风圈半径)
838
+ * @param {Object} pointInfo 台风点信息
839
+ * @returns {Object} 处理后的点信息
840
+ */
764
841
  getDivPointData(pointInfo) {
765
842
  if (pointInfo.radius7) pointInfo.radius7Arr = pointInfo.radius7.split('|');
766
843
  if (pointInfo.radius10) pointInfo.radius10Arr = pointInfo.radius10.split('|');
767
844
  if (pointInfo.radius12) pointInfo.radius12Arr = pointInfo.radius12.split('|');
768
845
  return pointInfo;
769
846
  }
770
- // 创建台风属性弹框
847
+ /**
848
+ * @description 创建台风播放属性弹框
849
+ * @param {Object} data 台风点数据
850
+ */
771
851
  createInfoPlayDivPoint(data) {
772
852
  data = Object.assign(data, this.currentRow);
773
853
  if (this._curTyphoon[data.tfid].divPoint) {
@@ -782,7 +862,11 @@ class TyphoonTracViewModel {
782
862
  noEvent: false
783
863
  });
784
864
  }
785
- //点击展示详细信息
865
+ /**
866
+ * @description 点击展示详细信息
867
+ * @param {Number} index 点索引
868
+ * @param {Object} row 台风行数据
869
+ */
786
870
  rowClickPath(index, row) {
787
871
  if (!this._curTyphoon[row.tfid]) {
788
872
  row.show = true;
@@ -794,7 +878,10 @@ class TyphoonTracViewModel {
794
878
  this.createInfoDivPoint(this.getDivPointData(this._curTyphoon[row.tfid].positions[index]));
795
879
  }, 500);
796
880
  }
797
- // 创建浮动弹框属性
881
+ /**
882
+ * @description 创建浮动弹框属性
883
+ * @param {Object} data 台风点数据
884
+ */
798
885
  createInfoDivPoint(data) {
799
886
  if (this.divPoint) {
800
887
  this.divPoint.destroy();
@@ -816,7 +903,11 @@ class TyphoonTracViewModel {
816
903
  anchor: [-140, htmlObj.anchorY]
817
904
  });
818
905
  }
819
- // 创建html弹框内容
906
+ /**
907
+ * @description 创建html弹框内容
908
+ * @param {Object} data 台风点数据
909
+ * @returns {Object} html内容和锚点对象
910
+ */
820
911
  createHtml(data) {
821
912
  let anchorY = -215;
822
913
  let html = `<div class='kq3d-typhoon-trac-Info'>
@@ -874,12 +965,22 @@ class TyphoonTracViewModel {
874
965
  anchorY: anchorY
875
966
  };
876
967
  }
877
- // 动态插入时进行字符过滤
968
+ /**
969
+ * @description 动态插入时进行字符过滤
970
+ * @param {String} text 待过滤文本
971
+ * @returns {String} 过滤后的文本
972
+ */
878
973
  sanitize(text) {
879
974
  return text.replace(/[\u200B-\u200D\uFEFF]/g, "") // 清除零宽字符
880
975
  .replace(/[“”]/g, ""); // 主动过滤引号
881
976
  }
882
- // 日期矫正
977
+ /**
978
+ * @description 日期矫正格式化
979
+ * @param {Date|String|Number} date 日期
980
+ * @param {String} format 格式类型('date'/'datetime')
981
+ * @param {Boolean} isPad 是否补零
982
+ * @returns {String} 格式化后的日期字符串
983
+ */
883
984
  formatDate(date = new Date(), format = 'datetime', isPad = true) {
884
985
  if (!(date instanceof Date)) {
885
986
  date = new Date(date);
@@ -901,11 +1002,17 @@ class TyphoonTracViewModel {
901
1002
  };
902
1003
  return Object.keys(dateFormats).reduce((result, item) => result.replaceAll(item, dateFormats[item]), format);
903
1004
  }
904
- // 停止播放
1005
+ /**
1006
+ * @description 停止播放台风轨迹
1007
+ * @param {Object} row 台风行数据
1008
+ */
905
1009
  stopPlayTyphoonTrac(row) {
906
1010
  if (this._curTyphoon[row.tfid]) this._curTyphoon[row.tfid].stop();
907
1011
  }
908
- // 暂停播放
1012
+ /**
1013
+ * @description 暂停/继续播放台风轨迹
1014
+ * @param {Boolean} val 是否继续播放
1015
+ */
909
1016
  pausePlayTyphoonTrac(val) {
910
1017
  if (this._curTyphoon[this.currentRow.tfid]) this._curTyphoon[this.currentRow.tfid].flyTo();
911
1018
  if (val) {
@@ -914,7 +1021,10 @@ class TyphoonTracViewModel {
914
1021
  this._viewer.clock.shouldAnimate = false;
915
1022
  }
916
1023
  }
917
- // 设置时间流速
1024
+ /**
1025
+ * @description 设置时间流速
1026
+ * @param {Number} val 流速倍数
1027
+ */
918
1028
  setMultiplier(val) {
919
1029
  window.viewer.clock.multiplier = val || 1;
920
1030
  }
@@ -993,6 +1103,10 @@ class TyphoonTracViewModel {
993
1103
  }
994
1104
  });
995
1105
  }
1106
+ /**
1107
+ * @description 移除指定台风
1108
+ * @param {String} tfid 台风ID
1109
+ */
996
1110
  remove(tfid) {
997
1111
  if (this._curTyphoon[tfid] && this._curTyphoon[tfid].getHoverEvent) {
998
1112
  let hishoverEvent = this._curTyphoon[tfid].getHoverEvent();
@@ -1014,6 +1128,10 @@ class TyphoonTracViewModel {
1014
1128
  }
1015
1129
  this._curTyphoon[tfid] = null;
1016
1130
  }
1131
+ /**
1132
+ * @description 清除指定台风的弹框
1133
+ * @param {String} tfid 台风ID
1134
+ */
1017
1135
  clearDivPoint(tfid) {
1018
1136
  if (this._curTyphoon[tfid] && this._curTyphoon[tfid].divPoint) {
1019
1137
  this._curTyphoon[tfid].divPoint.destroy();
@@ -95,6 +95,10 @@ exports["default"] = void 0;
95
95
  */
96
96
  class UndergroundViewModel {
97
97
  // 地下模式三维管理对象
98
+ /**
99
+ * @description 构造函数,初始化地下模式管理对象
100
+ * @param {Object} viewer 三维viewer对象
101
+ */
98
102
  constructor(viewer) {
99
103
  this._viewer = null;
100
104
  // 三维viewer对象
@@ -102,6 +106,8 @@ class UndergroundViewModel {
102
106
  this._viewer = viewer;
103
107
  this._undergroundManager = new Cesium.Kq3dUndergroundManager(this._viewer.scene);
104
108
  }
109
+
110
+ // 开启地下模式
105
111
  open() {
106
112
  // this._viewer.scene.skyAtmosphere.show = false;
107
113
  // 关闭碰撞检测
@@ -184,8 +190,8 @@ var _default = exports.A = /*@__PURE__*/Object.assign(__default__, {
184
190
  const emit = __emit;
185
191
  //获取组件传参
186
192
  const props = __props;
187
- let isUndergroundMode = (0, _vue.ref)(false);
188
- let viewModel = null;
193
+ let isUndergroundMode = (0, _vue.ref)(false); // 地下模式开关状态
194
+ let viewModel = null; // 地下模式视图模型对象
189
195
 
190
196
  // 组件容器Ref
191
197
  let boxRef = (0, _vue.ref)(null);