@kimap/indoor-positioning-sdk-vue2 5.4.4 → 5.4.6

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kimap/indoor-positioning-sdk-vue2",
3
- "version": "5.4.4",
3
+ "version": "5.4.6",
4
4
  "description": "Vue2自包含室内定位SDK - 完全兼容Webpack3+Babel6 | Vue2 Self-Contained Indoor Positioning SDK",
5
5
  "main": "index.js",
6
6
  "files": [
@@ -1183,6 +1183,9 @@
1183
1183
  // 与主应用 three-helper.ts 保持一致
1184
1184
  // =====================================================
1185
1185
  var depthWrite = true;
1186
+ var emissiveEnabled = false;
1187
+ var emissiveColor = 0x000000;
1188
+ var emissiveIntensity = 0;
1186
1189
 
1187
1190
  if (child.material.name.startsWith('Area_')) {
1188
1191
  roughness = 0.95; // 与three-helper.ts一致
@@ -1190,6 +1193,10 @@
1190
1193
  transparent = true; // 区域支持透明
1191
1194
  // 区域通常是高透明度的,关闭depthWrite避免与3D家具的深度冲突
1192
1195
  depthWrite = false;
1196
+ // 添加轻微emissive提亮区域颜色
1197
+ emissiveEnabled = true;
1198
+ emissiveColor = mtlColor; // 使用与主色相同的颜色
1199
+ emissiveIntensity = 0.15; // 15%发光强度,避免过亮
1193
1200
  // 收集区域网格(用于层级处理)
1194
1201
  areaMeshes.push(child);
1195
1202
  } else if (child.material.name.startsWith('Wall_')) {
@@ -1236,6 +1243,8 @@
1236
1243
  transparent: transparent,
1237
1244
  roughness: roughness,
1238
1245
  metalness: metalness,
1246
+ emissive: emissiveEnabled ? new THREE.Color(emissiveColor) : new THREE.Color(0x000000),
1247
+ emissiveIntensity: emissiveEnabled ? emissiveIntensity : 0,
1239
1248
  side: THREE.DoubleSide,
1240
1249
  depthWrite: depthWrite // 高透明度时关闭depthWrite避免频闪
1241
1250
  });
@@ -1248,7 +1257,9 @@
1248
1257
  metalness: metalness,
1249
1258
  opacity: opacity,
1250
1259
  transparent: transparent,
1251
- depthWrite: depthWrite
1260
+ depthWrite: depthWrite,
1261
+ emissive: emissiveEnabled ? '#' + emissiveColor.toString(16).padStart(6, '0') : 'none',
1262
+ emissiveIntensity: emissiveIntensity
1252
1263
  });
1253
1264
  return;
1254
1265
  }
@@ -849,17 +849,9 @@ KimapSDK.prototype._showSingleFloor = function(floorIndex) {
849
849
  });
850
850
  }
851
851
 
852
- // 背景建筑:始终保持Y=0紧贴地面,但降低透明度表示"非当前楼层"
852
+ // 背景建筑:单楼层模式下隐藏,仅在ALL模式显示
853
853
  if (this.backgroundGroup) {
854
- this.backgroundGroup.visible = true;
855
- this.backgroundGroup.position.y = 0; // 始终紧贴地面,不随楼层移动
856
-
857
- // 非第一楼层时降低透明度(使用淡入效果)
858
- if (floorIndex > 0) {
859
- this._fadeBackgroundBuildingsOpacity(0.4, 300); // 降低到40%透明度
860
- } else {
861
- this._fadeBackgroundBuildingsOpacity(0.7, 300); // 恢复正常透明度
862
- }
854
+ this.backgroundGroup.visible = false;
863
855
  }
864
856
 
865
857
  // 隐藏科技感地面