leiting-bim 2.1.162 → 2.1.164
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/leiting-bim.es.js +1 -1
- package/leiting-bim.umd.js +6 -6
- package/leitingbim.css +1 -1
- package/package.json +1 -1
- package/plugins/cesium-core/dist/cesium-core.mjs +2702 -1765
- package/plugins/cesium-core/dist/cesium-core.mjs.map +1 -1
- package/plugins/cesium-core/dist/cesium-core.umd.js +31 -31
- package/plugins/cesium-core/dist/cesium-core.umd.js.map +1 -1
- package/plugins/cesium-core/dist/components/gltf/GLTFManage.d.ts +86 -6
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { TooltipManager } from '../TooltipManager';
|
|
1
2
|
export declare enum EditMode {
|
|
2
3
|
Rotate = "rotate",
|
|
3
4
|
Move = "move",
|
|
@@ -19,14 +20,34 @@ export declare class GLTFManage {
|
|
|
19
20
|
viewer: any;
|
|
20
21
|
handler: any;
|
|
21
22
|
rotationRing: any;
|
|
23
|
+
moveAxis: any;
|
|
22
24
|
translationSquare: any;
|
|
23
25
|
heightArrow: any;
|
|
26
|
+
scaleHandle: any;
|
|
27
|
+
scaleCenterProxy: any;
|
|
24
28
|
editMode: EditMode;
|
|
25
29
|
dragEndCallbackMap: Map<string, any>;
|
|
30
|
+
activeModelId: string;
|
|
31
|
+
activeModelVisualState: Map<string, any>;
|
|
32
|
+
overlayContainer: HTMLDivElement | null;
|
|
33
|
+
modeToolbarEl: HTMLDivElement | null;
|
|
34
|
+
feedbackLabelEl: HTMLDivElement | null;
|
|
35
|
+
overlayUpdateFn: any;
|
|
36
|
+
feedbackAnchor: any;
|
|
37
|
+
tooltipManager: TooltipManager | null;
|
|
38
|
+
tooltipHideTimer: any;
|
|
39
|
+
scaleCenterHintVisible: boolean;
|
|
26
40
|
constructor(options: {
|
|
27
41
|
Cesium: any;
|
|
28
42
|
viewer: any;
|
|
29
43
|
});
|
|
44
|
+
isSceneGadgetDebugEnabled(): boolean;
|
|
45
|
+
debugLog(step: string, payload?: Record<string, any>): void;
|
|
46
|
+
getPickDebugId(hit: any): any;
|
|
47
|
+
debugPickStack(screenPosition: any, mode: EditMode): void;
|
|
48
|
+
showModeHint(text: string, duration?: number): void;
|
|
49
|
+
showHoverModeHint(text: string): void;
|
|
50
|
+
hideModeHint(): void;
|
|
30
51
|
/**
|
|
31
52
|
* @description: 初始化模型
|
|
32
53
|
* @param {Array<any>} models 模型数据列表
|
|
@@ -39,7 +60,7 @@ export declare class GLTFManage {
|
|
|
39
60
|
* @param {*} info 模型信息
|
|
40
61
|
* @return {*}
|
|
41
62
|
*/
|
|
42
|
-
add(info: any, show?: boolean): void
|
|
63
|
+
add(info: any, show?: boolean): Promise<void>;
|
|
43
64
|
flyTo(id: string): void;
|
|
44
65
|
/**
|
|
45
66
|
* @description: 根据模型的 ID 移除模型
|
|
@@ -64,6 +85,22 @@ export declare class GLTFManage {
|
|
|
64
85
|
*/
|
|
65
86
|
setScale(id: any, scale?: number): void;
|
|
66
87
|
setEditMode(mode: EditMode): void;
|
|
88
|
+
normalizeScaleVector(scale?: any): any;
|
|
89
|
+
getPrimitiveScale(primitive: any): {
|
|
90
|
+
x: number;
|
|
91
|
+
y: number;
|
|
92
|
+
z: number;
|
|
93
|
+
};
|
|
94
|
+
initializePrimitiveRuntimeState(primitive: any): void;
|
|
95
|
+
getPrimitiveRuntimeRadius(primitive: any): number;
|
|
96
|
+
cachePrimitiveUnitRadius(primitive: any, runtimeRadius?: number): number;
|
|
97
|
+
getPrimitiveFallbackRadius(primitive: any): number;
|
|
98
|
+
getPrimitiveEffectiveRadius(primitive: any): number;
|
|
99
|
+
getPrimitiveWorldBoundingSphere(primitive: any): any;
|
|
100
|
+
extractModelBaseMatrix(modelMatrix: any): any;
|
|
101
|
+
composeModelMatrix(position: any, headingPitchRoll: any, scale?: any): any;
|
|
102
|
+
applyScaleToPrimitive(primitive: any, scale: any, baseModelMatrix?: any): any;
|
|
103
|
+
getGizmoModelMatrix(model: any): any;
|
|
67
104
|
lockCamera(): void;
|
|
68
105
|
unlockCamera(): void;
|
|
69
106
|
toCartographic(cartesian: any): {
|
|
@@ -107,9 +144,50 @@ export declare class GLTFManage {
|
|
|
107
144
|
* @return {*}
|
|
108
145
|
*/
|
|
109
146
|
initEditBox(getEditState: Function): void;
|
|
147
|
+
activateEditById(id: string, mode?: EditMode): void;
|
|
148
|
+
deactivateEdit(clearMode?: boolean): void;
|
|
149
|
+
switchEditMode(mode: EditMode): void;
|
|
150
|
+
refreshActiveToolGeometry(): void;
|
|
151
|
+
highlightModel(model: any, active: boolean): void;
|
|
152
|
+
clearActiveModelVisual(): void;
|
|
153
|
+
initOverlay(): void;
|
|
154
|
+
showModeToolbar(id: string): void;
|
|
155
|
+
hideModeToolbar(): void;
|
|
156
|
+
updateToolbarState(): void;
|
|
157
|
+
updateOverlayPosition(): void;
|
|
158
|
+
showFeedback(text: string, anchor?: any): void;
|
|
159
|
+
hideFeedback(): void;
|
|
160
|
+
toWindowCoordinates(position: any): any;
|
|
161
|
+
createUnitBoxGeometry(): any;
|
|
162
|
+
getGizmoAppearance(): any;
|
|
163
|
+
getGizmoMetrics(model: any): {
|
|
164
|
+
centerRadius: number;
|
|
165
|
+
axisLength: number;
|
|
166
|
+
arrowLength: number;
|
|
167
|
+
arrowRadius: number;
|
|
168
|
+
axisThickness: number;
|
|
169
|
+
planeStart: number;
|
|
170
|
+
planeEnd: number;
|
|
171
|
+
planeThickness: number;
|
|
172
|
+
rotationRadius: number;
|
|
173
|
+
rotationThickness: number;
|
|
174
|
+
scaleOffset: number;
|
|
175
|
+
scaleHandleRadius: number;
|
|
176
|
+
};
|
|
177
|
+
createSegmentInstance(id: string, start: any, end: any, thickness: number, color: any): any;
|
|
178
|
+
createCenterInstance(id: string, radius: number, color: any): any;
|
|
179
|
+
createCenterBoxInstance(id: string, size: number, color: any): any;
|
|
180
|
+
getAxisVector(enuMatrix: any, axis: string): any;
|
|
181
|
+
getRotationPlanePoint(plane: 'xy' | 'yz' | 'xz', radius: number, angleRad: number): any;
|
|
182
|
+
getGizmoLocalBounds(model: any): any[];
|
|
183
|
+
getGizmoScreenBounds(model: any): any;
|
|
184
|
+
writeDragEndPayload(modelId: string, key: GLTFManageEventKey, payload: any): void;
|
|
185
|
+
applyTransformAroundCenter(startModelMatrix: any, center: any, transformMatrix: any): any;
|
|
186
|
+
createMoveAxis(model: any): void;
|
|
110
187
|
createRotationRing(model: any): void;
|
|
111
188
|
createTranslationSquare(model: any): void;
|
|
112
189
|
createHeightArrow(model: any): void;
|
|
190
|
+
createScaleHandle(model: any): void;
|
|
113
191
|
translate(geometry: any, offset: any): void;
|
|
114
192
|
removeTool(): void;
|
|
115
193
|
updatedTool(newModelMatrix: any): void;
|
|
@@ -117,10 +195,10 @@ export declare class GLTFManage {
|
|
|
117
195
|
* @description: 平移模型
|
|
118
196
|
* @param {*} draggedModel
|
|
119
197
|
* @param {*} startModelMatrix
|
|
120
|
-
* @param {*}
|
|
198
|
+
* @param {*} dragToolAxis
|
|
121
199
|
* @return {*}
|
|
122
200
|
*/
|
|
123
|
-
moveModel(draggedModel: any, startModelMatrix: any,
|
|
201
|
+
moveModel(draggedModel: any, startModelMatrix: any, dragToolAxis: string, dragStartCenter: any, dragStartPoint: any, newPoint: any): void;
|
|
124
202
|
/**
|
|
125
203
|
* @description: 平移模型高度
|
|
126
204
|
* @param {*} draggedModel
|
|
@@ -128,14 +206,16 @@ export declare class GLTFManage {
|
|
|
128
206
|
* @param {*} movement
|
|
129
207
|
* @return {*}
|
|
130
208
|
*/
|
|
131
|
-
moveModelHeight(draggedModel: any, startModelMatrix: any, movement: any,
|
|
209
|
+
moveModelHeight(draggedModel: any, startModelMatrix: any, movement: any, startBasePosition: any, startBaseUp: any, startBaseCartographic: any): void;
|
|
210
|
+
projectVerticalPoint(screenPosition: any, base: any, up: any): any;
|
|
132
211
|
/**
|
|
133
212
|
* @description: 旋转模型
|
|
134
213
|
* @param {*} draggedModel
|
|
135
214
|
* @param {*} startModelMatrix
|
|
136
|
-
* @param {*}
|
|
215
|
+
* @param {*} dragToolAxis
|
|
137
216
|
* @return {*}
|
|
138
217
|
*/
|
|
139
|
-
rotateModel(draggedModel: any, startModelMatrix: any,
|
|
218
|
+
rotateModel(draggedModel: any, startModelMatrix: any, dragToolAxis: string, dragStartCenter: any, dragVectorStart: any, newPoint: any): void;
|
|
219
|
+
moveModelScale(draggedModel: any, startModelMatrix: any, dragToolAxis: string, dragStartCenter: any, startMousePosition: any, dragStartPoint: any, startScaleVector: any, currentMousePosition: any, newPoint: any): void;
|
|
140
220
|
cleanup(): void;
|
|
141
221
|
}
|