@aibee/crc-bmap 0.14.23 → 0.14.25

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/lib/meta.json CHANGED
@@ -1268,6 +1268,11 @@
1268
1268
  "imports": [],
1269
1269
  "format": "esm"
1270
1270
  },
1271
+ "url-import:./icon/parkingSpace/gsadv.svg": {
1272
+ "bytes": 78,
1273
+ "imports": [],
1274
+ "format": "esm"
1275
+ },
1271
1276
  "url-import:./glb/locate.glb": {
1272
1277
  "bytes": 65,
1273
1278
  "imports": [],
@@ -1294,7 +1299,7 @@
1294
1299
  "format": "esm"
1295
1300
  },
1296
1301
  "../lib/src/assets/offline.js": {
1297
- "bytes": 1001,
1302
+ "bytes": 1102,
1298
1303
  "imports": [
1299
1304
  {
1300
1305
  "path": "url-import:./icon/parkingSpace/half.svg",
@@ -1316,6 +1321,11 @@
1316
1321
  "kind": "import-statement",
1317
1322
  "original": "./icon/parkingSpace/vip.svg"
1318
1323
  },
1324
+ {
1325
+ "path": "url-import:./icon/parkingSpace/gsadv.svg",
1326
+ "kind": "import-statement",
1327
+ "original": "./icon/parkingSpace/gsadv.svg"
1328
+ },
1319
1329
  {
1320
1330
  "path": "url-import:./glb/locate.glb",
1321
1331
  "kind": "import-statement",
@@ -1904,8 +1914,13 @@
1904
1914
  "format": "esm"
1905
1915
  },
1906
1916
  "../lib/src/layer/parking-layer.js": {
1907
- "bytes": 10013,
1917
+ "bytes": 10131,
1908
1918
  "imports": [
1919
+ {
1920
+ "path": "../../../node_modules/.pnpm/@swc+helpers@0.5.17/node_modules/@swc/helpers/esm/_extends.js",
1921
+ "kind": "import-statement",
1922
+ "original": "@swc/helpers/_/_extends"
1923
+ },
1909
1924
  {
1910
1925
  "path": "core-js/modules/es.regexp.exec.js",
1911
1926
  "kind": "import-statement",
@@ -2648,7 +2663,7 @@
2648
2663
  "format": "esm"
2649
2664
  },
2650
2665
  "../src/assets/offline.ts": {
2651
- "bytes": 1053,
2666
+ "bytes": 1153,
2652
2667
  "imports": [
2653
2668
  {
2654
2669
  "path": "url-import:./icon/parkingSpace/half.svg",
@@ -2670,6 +2685,11 @@
2670
2685
  "kind": "import-statement",
2671
2686
  "original": "./icon/parkingSpace/vip.svg"
2672
2687
  },
2688
+ {
2689
+ "path": "url-import:./icon/parkingSpace/gsadv.svg",
2690
+ "kind": "import-statement",
2691
+ "original": "./icon/parkingSpace/gsadv.svg"
2692
+ },
2673
2693
  {
2674
2694
  "path": "url-import:./glb/locate.glb",
2675
2695
  "kind": "import-statement",
@@ -5013,7 +5033,7 @@
5013
5033
  "format": "esm"
5014
5034
  },
5015
5035
  "../lib/src/types/index.js": {
5016
- "bytes": 614,
5036
+ "bytes": 673,
5017
5037
  "imports": [],
5018
5038
  "format": "esm"
5019
5039
  },
@@ -5203,7 +5223,7 @@
5203
5223
  "format": "esm"
5204
5224
  },
5205
5225
  "../lib/src/plugins/navigation/position-navigation.js": {
5206
- "bytes": 17071,
5226
+ "bytes": 19582,
5207
5227
  "imports": [
5208
5228
  {
5209
5229
  "path": "../../../node_modules/.pnpm/@swc+helpers@0.5.17/node_modules/@swc/helpers/esm/_extends.js",
@@ -6115,7 +6135,7 @@
6115
6135
  "format": "esm"
6116
6136
  },
6117
6137
  "../lib/src/plugins/car-inertial-position/car-inertial-position.js": {
6118
- "bytes": 17854,
6138
+ "bytes": 18464,
6119
6139
  "imports": [
6120
6140
  {
6121
6141
  "path": "../../../node_modules/.pnpm/@swc+helpers@0.5.17/node_modules/@swc/helpers/esm/_extends.js",
@@ -9706,6 +9726,9 @@
9706
9726
  "url-import:./icon/parkingSpace/vip.svg": {
9707
9727
  "bytesInOutput": 67
9708
9728
  },
9729
+ "url-import:./icon/parkingSpace/gsadv.svg": {
9730
+ "bytesInOutput": 69
9731
+ },
9709
9732
  "url-import:./glb/locate.glb": {
9710
9733
  "bytesInOutput": 56
9711
9734
  },
@@ -9722,7 +9745,7 @@
9722
9745
  "bytesInOutput": 69
9723
9746
  },
9724
9747
  "../lib/src/assets/offline.js": {
9725
- "bytesInOutput": 59
9748
+ "bytesInOutput": 68
9726
9749
  },
9727
9750
  "../lib/src/factory/worker/merge-geometry.worker.js": {
9728
9751
  "bytesInOutput": 103
@@ -9758,7 +9781,7 @@
9758
9781
  "bytesInOutput": 1754
9759
9782
  },
9760
9783
  "../lib/src/layer/parking-layer.js": {
9761
- "bytesInOutput": 4017
9784
+ "bytesInOutput": 4035
9762
9785
  },
9763
9786
  "../lib/src/layer/merged-model-layer.js": {
9764
9787
  "bytesInOutput": 252
@@ -9911,7 +9934,7 @@
9911
9934
  "bytesInOutput": 0
9912
9935
  },
9913
9936
  "../lib/src/types/index.js": {
9914
- "bytesInOutput": 119
9937
+ "bytesInOutput": 135
9915
9938
  },
9916
9939
  "../lib/src/plugins/equipment/equipment.js": {
9917
9940
  "bytesInOutput": 1524
@@ -9929,7 +9952,7 @@
9929
9952
  "bytesInOutput": 13835
9930
9953
  },
9931
9954
  "../lib/src/plugins/navigation/position-navigation.js": {
9932
- "bytesInOutput": 6648
9955
+ "bytesInOutput": 7115
9933
9956
  },
9934
9957
  "../lib/src/plugins/navigation/start-rotate-helper-poi.js": {
9935
9958
  "bytesInOutput": 3438
@@ -9992,7 +10015,7 @@
9992
10015
  "bytesInOutput": 1040
9993
10016
  },
9994
10017
  "../lib/src/plugins/car-inertial-position/car-inertial-position.js": {
9995
- "bytesInOutput": 6612
10018
+ "bytesInOutput": 6826
9996
10019
  },
9997
10020
  "../lib/src/plugins/car-inertial-position/utils.js": {
9998
10021
  "bytesInOutput": 1820
@@ -10046,7 +10069,7 @@
10046
10069
  "bytesInOutput": 0
10047
10070
  }
10048
10071
  },
10049
- "bytes": 439664
10072
+ "bytes": 440457
10050
10073
  }
10051
10074
  }
10052
10075
  }
@@ -24,6 +24,7 @@ export interface NavigationProcessInfo {
24
24
  imageUrl: string | null;
25
25
  nextDir: PathDirection;
26
26
  offsetDistance: number;
27
+ reverseAngle: number | null;
27
28
  }
28
29
  interface PositionNavigationEvent {
29
30
  "navigation-info": {
@@ -47,6 +48,7 @@ export declare class PositionNavigation extends EventDispatcher<PositionNavigati
47
48
  roadData: RoadData2[];
48
49
  paused: boolean;
49
50
  offsetDistance: number;
51
+ actualPosition: [number, number] | null;
50
52
  constructor(navigation: Navigation, options: Partial<PositionNavigationConfig>, roadData: RoadData2[]);
51
53
  get curRoutePath(): PathData2[0] | null;
52
54
  get curRoutePathPoints(): [number, number][];
@@ -85,6 +87,22 @@ export declare class PositionNavigation extends EventDispatcher<PositionNavigati
85
87
  nextAngle: number;
86
88
  nextDir: PathDirection;
87
89
  } | null;
90
+ /**
91
+ * 计算用户实际位置与吸附位置连线相对于当前路线前进方向的夹角
92
+ *
93
+ * 原理:
94
+ * 向量A = 实际位置 - 吸附位置 (吸附位置指向用户实际位置的方向)
95
+ * 向量B = 路线下一个点 - 吸附位置(路线前进方向)
96
+ * 夹角 = 向量A与向量B的夹角(0~180度)
97
+ *
98
+ * 当用户沿路线正向行走时,实际位置在吸附位置的前方,向量A与向量B方向基本一致,夹角接近 0°。
99
+ * 当用户走反方向时(canBack=false,吸附位置不跟随后退),实际位置在吸附位置的后方,
100
+ * 向量A指向路线反方向,夹角接近 180°,据此判断需要提示掉头。
101
+ *
102
+ * @param actualPos 可选,用户实际位置;不传则使用上次 toPosition 保存的值
103
+ * @returns 夹角(0~180度),null 表示无法计算(路线数据不足或位置重合)
104
+ */
105
+ calcReverseAngle(actualPos?: [number, number]): number | null;
88
106
  getCurPointAreaInfo(): {
89
107
  id: string;
90
108
  name: string;
@@ -158,6 +158,7 @@ export declare enum ParkingType {
158
158
  POWER = "power",
159
159
  MECHANICAL = "mechanical",
160
160
  NORMAL = "normal",
161
- VIP = "vip"
161
+ VIP = "vip",
162
+ GSADV = "gsadv"
162
163
  }
163
164
  export {};