@realsee/dnalogel 2.0.0 → 2.0.1
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/dist/CSS3DRenderPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/CameraMovementPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/CruisePlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/CruisePlugin/index.js +188 -5
- package/dist/GuideLinePlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/GuideLinePlugin/index.js +188 -5
- package/dist/ItemLabelPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/ItemLabelPlugin/index.js +2 -2
- package/dist/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/ModelChassisCompassPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/ModelEntryDoorGuidePlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/ModelItemLabelPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/ModelItemLabelPlugin/index.js +2 -2
- package/dist/ModelRoomLabelPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/ModelRoomLabelPlugin/index.js +2 -2
- package/dist/ModelTVVideoPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/ModelViewPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/PanoCompassPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/PanoCursorRaycasterPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/PanoDoorLabelPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/PanoDoorLabelPlugin/index.js +1 -1
- package/dist/PanoMeasurePlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/PanoRulerPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/PanoRulerProPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/PanoRulerProPlugin/index.js +2 -2
- package/dist/PanoSpatialTagPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/PanoSpatialTagPlugin/index.js +2 -2
- package/dist/floorplan/MapviewFloorplanPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/floorplan/MapviewFloorplanPlugin/index.js +17 -17
- package/dist/floorplan/ModelFloorplanPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/floorplan/ModelFloorplanPlugin/index.js +17 -17
- package/dist/floorplan/PanoFloorplanRadarPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/floorplan/PanoFloorplanRadarPlugin/index.js +9 -9
- package/dist/floorplan/TopviewFloorplanPlugin/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/dist/floorplan/TopviewFloorplanPlugin/index.js +17 -17
- package/dist/index.es.js +220 -34
- package/dist/index.js +220 -35
- package/dist/index.umd.js +224 -38
- package/docs/classes/CruisePluginController.html +1 -1
- package/docs/classes/Magnifier.html +1 -1
- package/docs/classes/ModelRoomLabelController.html +1 -1
- package/docs/enums/CameraMovementEffect.html +1 -1
- package/docs/enums/DIRECTION.html +1 -1
- package/docs/enums/DISPLAY_STRATEGY_TYPE.html +1 -1
- package/docs/enums/FLOOR_PLAN_ATTACHED_TO.html +1 -1
- package/docs/enums/ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE.html +1 -1
- package/docs/enums/Rotation.html +1 -1
- package/docs/index.html +1 -1
- package/docs/interfaces/CSS3DRenderPluginExportType.html +1 -1
- package/docs/interfaces/CameraMovementPluginExportType.html +1 -1
- package/docs/interfaces/FloorplanBounding.html +1 -1
- package/docs/interfaces/FloorplanData.html +1 -1
- package/docs/interfaces/FloorplanEntrance.html +1 -1
- package/docs/interfaces/FloorplanExtraObject.html +1 -1
- package/docs/interfaces/FloorplanExtraObject3D.html +1 -1
- package/docs/interfaces/FloorplanFloorData.html +1 -1
- package/docs/interfaces/FloorplanImagePosition.html +1 -1
- package/docs/interfaces/FloorplanObserver.html +1 -1
- package/docs/interfaces/FloorplanOutlineItem.html +1 -1
- package/docs/interfaces/FloorplanPosition.html +1 -1
- package/docs/interfaces/FloorplanRoomItem.html +1 -1
- package/docs/interfaces/FloorplanRoomLabelItem.html +1 -1
- package/docs/interfaces/FloorplanServerBounding.html +1 -1
- package/docs/interfaces/FloorplanServerComputedData.html +1 -1
- package/docs/interfaces/FloorplanServerData.html +1 -1
- package/docs/interfaces/FloorplanServerDoorItem.html +1 -1
- package/docs/interfaces/FloorplanServerDoorPosition.html +1 -1
- package/docs/interfaces/FloorplanServerEntrance.html +1 -1
- package/docs/interfaces/FloorplanServerFloorData.html +1 -1
- package/docs/interfaces/FloorplanServerImagePosition.html +1 -1
- package/docs/interfaces/FloorplanServerObserver.html +1 -1
- package/docs/interfaces/FloorplanServerOutlineItem.html +1 -1
- package/docs/interfaces/FloorplanServerPosition.html +1 -1
- package/docs/interfaces/FloorplanServerRoomItem.html +1 -1
- package/docs/interfaces/FloorplanServerRoomLabelItem.html +1 -1
- package/docs/interfaces/ItemLabelPluginData.html +1 -1
- package/docs/interfaces/ItemLabelPluginExportReturnsType.html +1 -1
- package/docs/interfaces/ItemLabelPluginParametersType.html +1 -1
- package/docs/interfaces/LineJson.html +1 -1
- package/docs/interfaces/ModelChassisCompassPluginData.html +1 -1
- package/docs/interfaces/ModelChassisCompassPluginExportType.html +1 -1
- package/docs/interfaces/ModelChassisCompassPluginParameterType.html +1 -1
- package/docs/interfaces/ModelEntryDoorGuidePluginData.html +1 -1
- package/docs/interfaces/ModelEntryDoorGuidePluginExportType.html +1 -1
- package/docs/interfaces/ModelItemLabelPluginData.html +1 -1
- package/docs/interfaces/ModelItemLabelPluginExportReturnsType.html +1 -1
- package/docs/interfaces/ModelItemLabelPluginParametersType.html +1 -1
- package/docs/interfaces/ModelRoomLabelPluginData.html +1 -1
- package/docs/interfaces/ModelTVVideoPluginData.html +1 -1
- package/docs/interfaces/ModelTVVideoPluginExportType.html +1 -1
- package/docs/interfaces/ModelTVVideoPluginParameterType.html +1 -1
- package/docs/interfaces/ModelViewPluginExportType.html +1 -1
- package/docs/interfaces/OpenParameter.html +1 -1
- package/docs/interfaces/PanoCursorRaycasterPluginExportType.html +1 -1
- package/docs/interfaces/PanoCursorRaycasterPluginParameterType.html +1 -1
- package/docs/interfaces/PanoMeasureParameterType.html +1 -1
- package/docs/interfaces/PanoRulerPluginExportType.html +1 -1
- package/docs/interfaces/PanoRulerPluginOptions.html +1 -1
- package/docs/interfaces/PanoRulerPluginParameterType.html +1 -1
- package/docs/interfaces/PanoRulerProPluginExportType.html +1 -1
- package/docs/interfaces/PanoRulerProPluginOptions.html +1 -1
- package/docs/interfaces/PanoRulerProPluginParameterType.html +1 -1
- package/docs/interfaces/PanoRulerProPluginState.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginContentEvent.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginContentReplacement.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginData.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginDataElement.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginExportType.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginOriginElement.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginParameterType.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginPointElement.html +1 -1
- package/docs/interfaces/PanoSpatialTagPluginTagElement.html +1 -1
- package/docs/interfaces/Point.html +1 -1
- package/docs/interfaces/PointJson.html +1 -1
- package/docs/interfaces/Room.html +1 -1
- package/docs/interfaces/RoomInfo.html +1 -1
- package/docs/interfaces/RoomLabel.html +1 -1
- package/docs/interfaces/RoomRules.html +1 -1
- package/docs/interfaces/Rooms.html +1 -1
- package/docs/modules.html +1 -1
- package/libs/ItemLabelPlugin/ItemLabelComponent.js +1 -1
- package/libs/ItemLabelPlugin/ItemLabelItem.js +1 -1
- package/libs/ItemLabelPlugin/utils/isImpacted.d.ts +2 -0
- package/libs/ModelItemLabelPlugin/ItemLabelComponent.js +1 -1
- package/libs/ModelItemLabelPlugin/ItemLabelItem.js +1 -1
- package/libs/ModelRoomLabelPlugin/RoomLabelItem.js +1 -1
- package/libs/ModelRoomLabelPlugin/RoomLabelItems.js +1 -1
- package/libs/PanoDoorLabelPlugin/DoorLabelItem.js +1 -1
- package/libs/PanoRulerProPlugin/RulerItem.js +1 -1
- package/libs/PanoRulerProPlugin/RulerItems.js +1 -1
- package/libs/PanoSpatialTagPlugin/Components/origins.js +1 -1
- package/libs/PanoSpatialTagPlugin/Components/tag.js +1 -1
- package/libs/floorplan/Components/BaseImage.js +1 -1
- package/libs/floorplan/Components/Camera.js +1 -1
- package/libs/floorplan/Components/Compass.js +1 -1
- package/libs/floorplan/Components/CurrentFloor.js +1 -1
- package/libs/floorplan/Components/Main.js +1 -1
- package/libs/floorplan/Components/Normalmage.js +1 -1
- package/libs/floorplan/Components/RoomHighlight/Room.js +1 -1
- package/libs/floorplan/Components/RoomHighlight/RoomHighlight.js +1 -1
- package/libs/floorplan/Components/RoomLabels/RoomLabel.js +1 -1
- package/libs/floorplan/Components/RoomLabels/RoomLabels.js +1 -1
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial.js +1 -1
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_0.js +1 -1
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_1.js +1 -1
- package/libs/floorplan/Components/RoomMaterials/RoomMaterial_2.js +1 -1
- package/libs/floorplan/Components/RuleLabels/RuleItem.js +1 -1
- package/libs/floorplan/Components/RuleLabels/RuleLabels.js +1 -1
- package/libs/floorplan/Components/SvgImage.js +1 -1
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Camera.js +1 -1
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/CurrentFloor.js +1 -1
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/CurrentFloor/ExtraObjects.js +1 -1
- package/libs/floorplan/PanoFloorplanRadarPlugin/Components/Main.js +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -4,9 +4,6 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var five = require('@realsee/five');
|
|
6
6
|
var THREE = require('three');
|
|
7
|
-
var getNormals = require('polyline-normals');
|
|
8
|
-
|
|
9
|
-
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
10
7
|
|
|
11
8
|
function _interopNamespace(e) {
|
|
12
9
|
if (e && e.__esModule) return e;
|
|
@@ -27,7 +24,6 @@ function _interopNamespace(e) {
|
|
|
27
24
|
}
|
|
28
25
|
|
|
29
26
|
var THREE__namespace = /*#__PURE__*/_interopNamespace(THREE);
|
|
30
|
-
var getNormals__default = /*#__PURE__*/_interopDefaultLegacy(getNormals);
|
|
31
27
|
|
|
32
28
|
/**
|
|
33
29
|
* plugin 的基本控制器
|
|
@@ -62,6 +58,193 @@ class Controller$2 {
|
|
|
62
58
|
class Controller$1 extends Controller$2 {
|
|
63
59
|
}
|
|
64
60
|
|
|
61
|
+
var polylineMiterUtil = {};
|
|
62
|
+
|
|
63
|
+
var add_1 = add$1;
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Adds two vec2's
|
|
67
|
+
*
|
|
68
|
+
* @param {vec2} out the receiving vector
|
|
69
|
+
* @param {vec2} a the first operand
|
|
70
|
+
* @param {vec2} b the second operand
|
|
71
|
+
* @returns {vec2} out
|
|
72
|
+
*/
|
|
73
|
+
function add$1(out, a, b) {
|
|
74
|
+
out[0] = a[0] + b[0];
|
|
75
|
+
out[1] = a[1] + b[1];
|
|
76
|
+
return out
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
var set_1 = set$1;
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* Set the components of a vec2 to the given values
|
|
83
|
+
*
|
|
84
|
+
* @param {vec2} out the receiving vector
|
|
85
|
+
* @param {Number} x X component
|
|
86
|
+
* @param {Number} y Y component
|
|
87
|
+
* @returns {vec2} out
|
|
88
|
+
*/
|
|
89
|
+
function set$1(out, x, y) {
|
|
90
|
+
out[0] = x;
|
|
91
|
+
out[1] = y;
|
|
92
|
+
return out
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
var normalize_1 = normalize$1;
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* Normalize a vec2
|
|
99
|
+
*
|
|
100
|
+
* @param {vec2} out the receiving vector
|
|
101
|
+
* @param {vec2} a vector to normalize
|
|
102
|
+
* @returns {vec2} out
|
|
103
|
+
*/
|
|
104
|
+
function normalize$1(out, a) {
|
|
105
|
+
var x = a[0],
|
|
106
|
+
y = a[1];
|
|
107
|
+
var len = x*x + y*y;
|
|
108
|
+
if (len > 0) {
|
|
109
|
+
//TODO: evaluate use of glm_invsqrt here?
|
|
110
|
+
len = 1 / Math.sqrt(len);
|
|
111
|
+
out[0] = a[0] * len;
|
|
112
|
+
out[1] = a[1] * len;
|
|
113
|
+
}
|
|
114
|
+
return out
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
var subtract_1 = subtract$1;
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* Subtracts vector b from vector a
|
|
121
|
+
*
|
|
122
|
+
* @param {vec2} out the receiving vector
|
|
123
|
+
* @param {vec2} a the first operand
|
|
124
|
+
* @param {vec2} b the second operand
|
|
125
|
+
* @returns {vec2} out
|
|
126
|
+
*/
|
|
127
|
+
function subtract$1(out, a, b) {
|
|
128
|
+
out[0] = a[0] - b[0];
|
|
129
|
+
out[1] = a[1] - b[1];
|
|
130
|
+
return out
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
var dot_1 = dot$1;
|
|
134
|
+
|
|
135
|
+
/**
|
|
136
|
+
* Calculates the dot product of two vec2's
|
|
137
|
+
*
|
|
138
|
+
* @param {vec2} a the first operand
|
|
139
|
+
* @param {vec2} b the second operand
|
|
140
|
+
* @returns {Number} dot product of a and b
|
|
141
|
+
*/
|
|
142
|
+
function dot$1(a, b) {
|
|
143
|
+
return a[0] * b[0] + a[1] * b[1]
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
var add = add_1;
|
|
147
|
+
var set = set_1;
|
|
148
|
+
var normalize = normalize_1;
|
|
149
|
+
var subtract = subtract_1;
|
|
150
|
+
var dot = dot_1;
|
|
151
|
+
|
|
152
|
+
var tmp = [0, 0];
|
|
153
|
+
|
|
154
|
+
polylineMiterUtil.computeMiter = function computeMiter(tangent, miter, lineA, lineB, halfThick) {
|
|
155
|
+
//get tangent line
|
|
156
|
+
add(tangent, lineA, lineB);
|
|
157
|
+
normalize(tangent, tangent);
|
|
158
|
+
|
|
159
|
+
//get miter as a unit vector
|
|
160
|
+
set(miter, -tangent[1], tangent[0]);
|
|
161
|
+
set(tmp, -lineA[1], lineA[0]);
|
|
162
|
+
|
|
163
|
+
//get the necessary length of our miter
|
|
164
|
+
return halfThick / dot(miter, tmp)
|
|
165
|
+
};
|
|
166
|
+
|
|
167
|
+
polylineMiterUtil.normal = function normal(out, dir) {
|
|
168
|
+
//get perpendicular
|
|
169
|
+
set(out, -dir[1], dir[0]);
|
|
170
|
+
return out
|
|
171
|
+
};
|
|
172
|
+
|
|
173
|
+
polylineMiterUtil.direction = function direction(out, a, b) {
|
|
174
|
+
//get unit dir of two lines
|
|
175
|
+
subtract(out, a, b);
|
|
176
|
+
normalize(out, out);
|
|
177
|
+
return out
|
|
178
|
+
};
|
|
179
|
+
|
|
180
|
+
var util = polylineMiterUtil;
|
|
181
|
+
|
|
182
|
+
var lineA = [0, 0];
|
|
183
|
+
var lineB = [0, 0];
|
|
184
|
+
var tangent = [0, 0];
|
|
185
|
+
var miter = [0, 0];
|
|
186
|
+
|
|
187
|
+
var polylineNormals = function(points, closed) {
|
|
188
|
+
var curNormal = null;
|
|
189
|
+
var out = [];
|
|
190
|
+
if (closed) {
|
|
191
|
+
points = points.slice();
|
|
192
|
+
points.push(points[0]);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
var total = points.length;
|
|
196
|
+
for (var i=1; i<total; i++) {
|
|
197
|
+
var last = points[i-1];
|
|
198
|
+
var cur = points[i];
|
|
199
|
+
var next = i<points.length-1 ? points[i+1] : null;
|
|
200
|
+
|
|
201
|
+
util.direction(lineA, cur, last);
|
|
202
|
+
if (!curNormal) {
|
|
203
|
+
curNormal = [0, 0];
|
|
204
|
+
util.normal(curNormal, lineA);
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
if (i === 1) //add initial normals
|
|
208
|
+
addNext(out, curNormal, 1);
|
|
209
|
+
|
|
210
|
+
if (!next) { //no miter, simple segment
|
|
211
|
+
util.normal(curNormal, lineA); //reset normal
|
|
212
|
+
addNext(out, curNormal, 1);
|
|
213
|
+
} else { //miter with last
|
|
214
|
+
//get unit dir of next line
|
|
215
|
+
util.direction(lineB, next, cur);
|
|
216
|
+
|
|
217
|
+
//stores tangent & miter
|
|
218
|
+
var miterLen = util.computeMiter(tangent, miter, lineA, lineB, 1);
|
|
219
|
+
addNext(out, miter, miterLen);
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
//if the polyline is a closed loop, clean up the last normal
|
|
224
|
+
if (points.length > 2 && closed) {
|
|
225
|
+
var last2 = points[total-2];
|
|
226
|
+
var cur2 = points[0];
|
|
227
|
+
var next2 = points[1];
|
|
228
|
+
|
|
229
|
+
util.direction(lineA, cur2, last2);
|
|
230
|
+
util.direction(lineB, next2, cur2);
|
|
231
|
+
util.normal(curNormal, lineA);
|
|
232
|
+
|
|
233
|
+
var miterLen2 = util.computeMiter(tangent, miter, lineA, lineB, 1);
|
|
234
|
+
out[0][0] = miter.slice();
|
|
235
|
+
out[total-1][0] = miter.slice();
|
|
236
|
+
out[0][1] = miterLen2;
|
|
237
|
+
out[total-1][1] = miterLen2;
|
|
238
|
+
out.pop();
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
return out
|
|
242
|
+
};
|
|
243
|
+
|
|
244
|
+
function addNext(out, normal, length) {
|
|
245
|
+
out.push([[normal[0], normal[1]], length]);
|
|
246
|
+
}
|
|
247
|
+
|
|
65
248
|
// 定义常量
|
|
66
249
|
const TRIANGLE_NUMBER_OF_RECTANGLE = 2; // 每个矩形有两个三角形
|
|
67
250
|
const VERTEX_NUMBER_OF_TRIANGLE = 3; // 每个三角形有三个顶点
|
|
@@ -179,7 +362,7 @@ function getLineGeometry(curvePoints, unitWidth, unitHeight) {
|
|
|
179
362
|
const halfUnitWidth = unitWidth / 2;
|
|
180
363
|
const aspect = unitHeight / unitWidth; // 纵横比 height / width
|
|
181
364
|
const curvePointsLength = curvePoints.length;
|
|
182
|
-
const normals =
|
|
365
|
+
const normals = polylineNormals(curvePoints.map((p) => [p.x, p.z])); // curvePoints:每个点切线的向量「二维」
|
|
183
366
|
const rectangleNumber = curvePoints.length - 1; // 曲线上 N 个点,构成了 N - 1 个矩形
|
|
184
367
|
const indexNumber = rectangleNumber * TRIANGLE_NUMBER_OF_RECTANGLE * VERTEX_NUMBER_OF_TRIANGLE;
|
|
185
368
|
const verticesNumber = 2 * curvePointsLength; // 顶点数量(包含公用):每个曲线点对应两个顶点,N 个 点有 2N 个顶点
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -4,9 +4,6 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var five = require('@realsee/five');
|
|
6
6
|
var THREE = require('three');
|
|
7
|
-
var getNormals = require('polyline-normals');
|
|
8
|
-
|
|
9
|
-
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
10
7
|
|
|
11
8
|
function _interopNamespace(e) {
|
|
12
9
|
if (e && e.__esModule) return e;
|
|
@@ -27,7 +24,6 @@ function _interopNamespace(e) {
|
|
|
27
24
|
}
|
|
28
25
|
|
|
29
26
|
var THREE__namespace = /*#__PURE__*/_interopNamespace(THREE);
|
|
30
|
-
var getNormals__default = /*#__PURE__*/_interopDefaultLegacy(getNormals);
|
|
31
27
|
|
|
32
28
|
/**
|
|
33
29
|
* plugin 的基本控制器
|
|
@@ -62,6 +58,193 @@ class Controller$2 {
|
|
|
62
58
|
class Controller$1 extends Controller$2 {
|
|
63
59
|
}
|
|
64
60
|
|
|
61
|
+
var polylineMiterUtil = {};
|
|
62
|
+
|
|
63
|
+
var add_1 = add$1;
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Adds two vec2's
|
|
67
|
+
*
|
|
68
|
+
* @param {vec2} out the receiving vector
|
|
69
|
+
* @param {vec2} a the first operand
|
|
70
|
+
* @param {vec2} b the second operand
|
|
71
|
+
* @returns {vec2} out
|
|
72
|
+
*/
|
|
73
|
+
function add$1(out, a, b) {
|
|
74
|
+
out[0] = a[0] + b[0];
|
|
75
|
+
out[1] = a[1] + b[1];
|
|
76
|
+
return out
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
var set_1 = set$1;
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* Set the components of a vec2 to the given values
|
|
83
|
+
*
|
|
84
|
+
* @param {vec2} out the receiving vector
|
|
85
|
+
* @param {Number} x X component
|
|
86
|
+
* @param {Number} y Y component
|
|
87
|
+
* @returns {vec2} out
|
|
88
|
+
*/
|
|
89
|
+
function set$1(out, x, y) {
|
|
90
|
+
out[0] = x;
|
|
91
|
+
out[1] = y;
|
|
92
|
+
return out
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
var normalize_1 = normalize$1;
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* Normalize a vec2
|
|
99
|
+
*
|
|
100
|
+
* @param {vec2} out the receiving vector
|
|
101
|
+
* @param {vec2} a vector to normalize
|
|
102
|
+
* @returns {vec2} out
|
|
103
|
+
*/
|
|
104
|
+
function normalize$1(out, a) {
|
|
105
|
+
var x = a[0],
|
|
106
|
+
y = a[1];
|
|
107
|
+
var len = x*x + y*y;
|
|
108
|
+
if (len > 0) {
|
|
109
|
+
//TODO: evaluate use of glm_invsqrt here?
|
|
110
|
+
len = 1 / Math.sqrt(len);
|
|
111
|
+
out[0] = a[0] * len;
|
|
112
|
+
out[1] = a[1] * len;
|
|
113
|
+
}
|
|
114
|
+
return out
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
var subtract_1 = subtract$1;
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* Subtracts vector b from vector a
|
|
121
|
+
*
|
|
122
|
+
* @param {vec2} out the receiving vector
|
|
123
|
+
* @param {vec2} a the first operand
|
|
124
|
+
* @param {vec2} b the second operand
|
|
125
|
+
* @returns {vec2} out
|
|
126
|
+
*/
|
|
127
|
+
function subtract$1(out, a, b) {
|
|
128
|
+
out[0] = a[0] - b[0];
|
|
129
|
+
out[1] = a[1] - b[1];
|
|
130
|
+
return out
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
var dot_1 = dot$1;
|
|
134
|
+
|
|
135
|
+
/**
|
|
136
|
+
* Calculates the dot product of two vec2's
|
|
137
|
+
*
|
|
138
|
+
* @param {vec2} a the first operand
|
|
139
|
+
* @param {vec2} b the second operand
|
|
140
|
+
* @returns {Number} dot product of a and b
|
|
141
|
+
*/
|
|
142
|
+
function dot$1(a, b) {
|
|
143
|
+
return a[0] * b[0] + a[1] * b[1]
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
var add = add_1;
|
|
147
|
+
var set = set_1;
|
|
148
|
+
var normalize = normalize_1;
|
|
149
|
+
var subtract = subtract_1;
|
|
150
|
+
var dot = dot_1;
|
|
151
|
+
|
|
152
|
+
var tmp = [0, 0];
|
|
153
|
+
|
|
154
|
+
polylineMiterUtil.computeMiter = function computeMiter(tangent, miter, lineA, lineB, halfThick) {
|
|
155
|
+
//get tangent line
|
|
156
|
+
add(tangent, lineA, lineB);
|
|
157
|
+
normalize(tangent, tangent);
|
|
158
|
+
|
|
159
|
+
//get miter as a unit vector
|
|
160
|
+
set(miter, -tangent[1], tangent[0]);
|
|
161
|
+
set(tmp, -lineA[1], lineA[0]);
|
|
162
|
+
|
|
163
|
+
//get the necessary length of our miter
|
|
164
|
+
return halfThick / dot(miter, tmp)
|
|
165
|
+
};
|
|
166
|
+
|
|
167
|
+
polylineMiterUtil.normal = function normal(out, dir) {
|
|
168
|
+
//get perpendicular
|
|
169
|
+
set(out, -dir[1], dir[0]);
|
|
170
|
+
return out
|
|
171
|
+
};
|
|
172
|
+
|
|
173
|
+
polylineMiterUtil.direction = function direction(out, a, b) {
|
|
174
|
+
//get unit dir of two lines
|
|
175
|
+
subtract(out, a, b);
|
|
176
|
+
normalize(out, out);
|
|
177
|
+
return out
|
|
178
|
+
};
|
|
179
|
+
|
|
180
|
+
var util = polylineMiterUtil;
|
|
181
|
+
|
|
182
|
+
var lineA = [0, 0];
|
|
183
|
+
var lineB = [0, 0];
|
|
184
|
+
var tangent = [0, 0];
|
|
185
|
+
var miter = [0, 0];
|
|
186
|
+
|
|
187
|
+
var polylineNormals = function(points, closed) {
|
|
188
|
+
var curNormal = null;
|
|
189
|
+
var out = [];
|
|
190
|
+
if (closed) {
|
|
191
|
+
points = points.slice();
|
|
192
|
+
points.push(points[0]);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
var total = points.length;
|
|
196
|
+
for (var i=1; i<total; i++) {
|
|
197
|
+
var last = points[i-1];
|
|
198
|
+
var cur = points[i];
|
|
199
|
+
var next = i<points.length-1 ? points[i+1] : null;
|
|
200
|
+
|
|
201
|
+
util.direction(lineA, cur, last);
|
|
202
|
+
if (!curNormal) {
|
|
203
|
+
curNormal = [0, 0];
|
|
204
|
+
util.normal(curNormal, lineA);
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
if (i === 1) //add initial normals
|
|
208
|
+
addNext(out, curNormal, 1);
|
|
209
|
+
|
|
210
|
+
if (!next) { //no miter, simple segment
|
|
211
|
+
util.normal(curNormal, lineA); //reset normal
|
|
212
|
+
addNext(out, curNormal, 1);
|
|
213
|
+
} else { //miter with last
|
|
214
|
+
//get unit dir of next line
|
|
215
|
+
util.direction(lineB, next, cur);
|
|
216
|
+
|
|
217
|
+
//stores tangent & miter
|
|
218
|
+
var miterLen = util.computeMiter(tangent, miter, lineA, lineB, 1);
|
|
219
|
+
addNext(out, miter, miterLen);
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
//if the polyline is a closed loop, clean up the last normal
|
|
224
|
+
if (points.length > 2 && closed) {
|
|
225
|
+
var last2 = points[total-2];
|
|
226
|
+
var cur2 = points[0];
|
|
227
|
+
var next2 = points[1];
|
|
228
|
+
|
|
229
|
+
util.direction(lineA, cur2, last2);
|
|
230
|
+
util.direction(lineB, next2, cur2);
|
|
231
|
+
util.normal(curNormal, lineA);
|
|
232
|
+
|
|
233
|
+
var miterLen2 = util.computeMiter(tangent, miter, lineA, lineB, 1);
|
|
234
|
+
out[0][0] = miter.slice();
|
|
235
|
+
out[total-1][0] = miter.slice();
|
|
236
|
+
out[0][1] = miterLen2;
|
|
237
|
+
out[total-1][1] = miterLen2;
|
|
238
|
+
out.pop();
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
return out
|
|
242
|
+
};
|
|
243
|
+
|
|
244
|
+
function addNext(out, normal, length) {
|
|
245
|
+
out.push([[normal[0], normal[1]], length]);
|
|
246
|
+
}
|
|
247
|
+
|
|
65
248
|
// 定义常量
|
|
66
249
|
const TRIANGLE_NUMBER_OF_RECTANGLE = 2; // 每个矩形有两个三角形
|
|
67
250
|
const VERTEX_NUMBER_OF_TRIANGLE = 3; // 每个三角形有三个顶点
|
|
@@ -179,7 +362,7 @@ function getLineGeometry(curvePoints, unitWidth, unitHeight) {
|
|
|
179
362
|
const halfUnitWidth = unitWidth / 2;
|
|
180
363
|
const aspect = unitHeight / unitWidth; // 纵横比 height / width
|
|
181
364
|
const curvePointsLength = curvePoints.length;
|
|
182
|
-
const normals =
|
|
365
|
+
const normals = polylineNormals(curvePoints.map((p) => [p.x, p.z])); // curvePoints:每个点切线的向量「二维」
|
|
183
366
|
const rectangleNumber = curvePoints.length - 1; // 曲线上 N 个点,构成了 N - 1 个矩形
|
|
184
367
|
const indexNumber = rectangleNumber * TRIANGLE_NUMBER_OF_RECTANGLE * VERTEX_NUMBER_OF_TRIANGLE;
|
|
185
368
|
const verticesNumber = 2 * curvePointsLength; // 顶点数量(包含公用):每个曲线点对应两个顶点,N 个 点有 2N 个顶点
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -39,7 +39,7 @@ exports.ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE = void 0;
|
|
|
39
39
|
ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE["EXTRA_LARGE"] = "x-large";
|
|
40
40
|
})(exports.ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE || (exports.ITEM_LABEL_PLUGIN_DISPLAY_STRATEGY_TYPE = {}));
|
|
41
41
|
|
|
42
|
-
/* src/ItemLabelPlugin/ItemLabelItem.svelte generated by Svelte v3.
|
|
42
|
+
/* src/ItemLabelPlugin/ItemLabelItem.svelte generated by Svelte v3.50.1 */
|
|
43
43
|
|
|
44
44
|
function add_css$1(target) {
|
|
45
45
|
internal.append_styles(target, "svelte-1mppr0a", ".item-label-item.svelte-1mppr0a.svelte-1mppr0a{position:absolute;z-index:0;transform:none;cursor:pointer;pointer-events:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-animation:svelte-1mppr0a-fadeIn .3s ease-in;animation:svelte-1mppr0a-fadeIn .3s ease-in}.item-label-item.fold.svelte-1mppr0a>.item-label-item__text-wrap.svelte-1mppr0a{visibility:hidden}.item-label-item.fold.svelte-1mppr0a>.item-label-item__bar.anchor.svelte-1mppr0a{visibility:hidden}.item-label-item.fold.svelte-1mppr0a>.item-label-item__bar.anchor.svelte-1mppr0a:after{visibility:visible}.item-label-item__text-wrap.svelte-1mppr0a.svelte-1mppr0a{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;padding:0.625rem 1.04167rem 0.625rem 0.625rem;position:absolute;width:-webkit-max-content;width:-moz-max-content;width:max-content;max-width:24.63542rem;min-height:4.79167rem;background-image:linear-gradient(269deg, rgba(0, 0, 0, 0.50) 0%, rgba(0, 0, 0, 0.60) 49%, rgba(31, 38, 46, 0.70) 100%);border:1.5px solid rgba(255, 255, 255, .65);border-radius:0.15625rem;color:white;transform:translate(-50%, 0);display:flex;justify-content:flex-start;align-items:center;box-sizing:border-box;overflow:hidden;pointer-events:all}.item-label-item__custom.svelte-1mppr0a.svelte-1mppr0a{padding:0;max-width:unset;min-height:unset;background-image:unset;border:0;border-radius:0}.icon-wrap.svelte-1mppr0a.svelte-1mppr0a{width:3.54167rem;height:100%;display:flex;justify-content:center;align-content:center}.icon.svelte-1mppr0a.svelte-1mppr0a{width:3.54167rem;height:3.54167rem;background-repeat:no-repeat;background-size:contain;background-position:center}.item-label-text.svelte-1mppr0a.svelte-1mppr0a{margin-left:0.625rem;padding-left:0.625rem;min-height:3.54167rem;height:auto;display:flex;flex-flow:column;justify-content:space-around;align-content:flex-start;border-left:solid rgba(255, 255, 255, .2) 1px;border-top:solid rgba(255, 255, 255, .2) 0;border-right:solid rgba(255, 255, 255, .2) 0;border-bottom:solid rgba(255, 255, 255, .2) 0;pointer-events:auto}.item-model.svelte-1mppr0a.svelte-1mppr0a{white-space:nowrap;font-size:1.14583rem;font-weight:bold;line-height:1.5625rem}.item-name.svelte-1mppr0a.svelte-1mppr0a{height:auto;word-wrap:break-word;word-break:break-all;font-size:1.04167rem;line-height:1.45833rem}.item-label-item__bar.svelte-1mppr0a.svelte-1mppr0a{position:absolute;bottom:0;width:0.15625rem;background-image:linear-gradient(to bottom, white, rgba(255, 255, 255, 0));box-shadow:0 2px 0.41667rem 0 rgba(0, 0, 0, 0.20);pointer-events:none}.item-label-item__bar.anchor.svelte-1mppr0a.svelte-1mppr0a:after{content:'';position:absolute;bottom:0;width:1.25rem;height:1.25rem;background-image:url(\"//vrlab-public.ljcdn.com/common/file/web/67e7a198-28c9-47dc-879b-507bd3ae600c.png \");background-position:center;background-size:contain;transform:translate(-0.54688rem, 50%)}@-webkit-keyframes svelte-1mppr0a-fadeIn{from{opacity:0\n }to{opacity:1\n }}@keyframes svelte-1mppr0a-fadeIn{from{opacity:0\n }to{opacity:1\n }}");
|
|
@@ -403,7 +403,7 @@ function transform2RenderData(data) {
|
|
|
403
403
|
return data.map(label => (Object.assign({ observerIndex: undefined, visible: false, isFold: false }, label)));
|
|
404
404
|
}
|
|
405
405
|
|
|
406
|
-
/* src/ItemLabelPlugin/ItemLabelComponent.svelte generated by Svelte v3.
|
|
406
|
+
/* src/ItemLabelPlugin/ItemLabelComponent.svelte generated by Svelte v3.50.1 */
|
|
407
407
|
|
|
408
408
|
function add_css(target) {
|
|
409
409
|
internal.append_styles(target, "svelte-gk8s47", ".item-labels-container.svelte-gk8s47{width:100%;height:100%;position:relative}");
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -39,7 +39,7 @@ exports.DISPLAY_STRATEGY_TYPE = void 0;
|
|
|
39
39
|
DISPLAY_STRATEGY_TYPE["EXTRA_LARGE"] = "x-large";
|
|
40
40
|
})(exports.DISPLAY_STRATEGY_TYPE || (exports.DISPLAY_STRATEGY_TYPE = {}));
|
|
41
41
|
|
|
42
|
-
/* src/ModelItemLabelPlugin/ItemLabelItem.svelte generated by Svelte v3.
|
|
42
|
+
/* src/ModelItemLabelPlugin/ItemLabelItem.svelte generated by Svelte v3.50.1 */
|
|
43
43
|
|
|
44
44
|
function add_css$1(target) {
|
|
45
45
|
internal.append_styles(target, "svelte-n1c1kg", ".item-label-item.svelte-n1c1kg{position:absolute;z-index:0;transform:none;cursor:pointer;pointer-events:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:0}.item-label-item.visible.svelte-n1c1kg{opacity:1;-webkit-animation:svelte-n1c1kg-fadeIn .3s ease-in;animation:svelte-n1c1kg-fadeIn .3s ease-in}.item-label-item__text-wrap.svelte-n1c1kg::before{content:'';position:absolute;width:100%;height:100%;background-color:rgba(0, 0, 0, .3);filter:blur(0.83333rem);z-index:-1}.item-label-item__text-wrap.svelte-n1c1kg{padding:0.3125rem 0.3125rem 0;position:absolute;height:1.04167rem;pointer-events:all;background-size:100% 100%;background-repeat:no-repeat;white-space:nowrap;line-height:0.52083rem;font-size:0.57292rem;font-weight:bold;color:#FFEAC0;transform:translate(-50%, 0);display:flex;justify-content:center;align-items:center}.item-label-item__text.svelte-n1c1kg{padding-bottom:0.20833rem;border-top:0 solid;border-left:0 solid;border-right:0 solid;border-bottom:1px solid;-o-border-image:linear-gradient(to right, rgba(234, 208, 154, 0), rgba(234, 208, 154, 100), rgba(234, 208, 154, 0)) 4.5 1 4.5;border-image:linear-gradient(to right, rgba(234, 208, 154, 0), rgba(234, 208, 154, 100), rgba(234, 208, 154, 0)) 4.5 1 4.5}.item-label-item__bar.svelte-n1c1kg{position:absolute;bottom:0;width:1px;background-image:linear-gradient(to bottom, rgba(234, 208, 154, 0), rgba(234, 208, 154, 1))}@-webkit-keyframes svelte-n1c1kg-fadeIn{from{opacity:0\n }to{opacity:1\n }}@keyframes svelte-n1c1kg-fadeIn{from{opacity:0\n }to{opacity:1\n }}");
|
|
@@ -165,7 +165,7 @@ function debounce(func, wait = 200) {
|
|
|
165
165
|
};
|
|
166
166
|
}
|
|
167
167
|
|
|
168
|
-
/* src/ModelItemLabelPlugin/ItemLabelComponent.svelte generated by Svelte v3.
|
|
168
|
+
/* src/ModelItemLabelPlugin/ItemLabelComponent.svelte generated by Svelte v3.50.1 */
|
|
169
169
|
|
|
170
170
|
function add_css(target) {
|
|
171
171
|
internal.append_styles(target, "svelte-gk8s47", ".item-labels-container.svelte-gk8s47{width:100%;height:100%;position:relative}");
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -8,7 +8,7 @@ var three = require('three');
|
|
|
8
8
|
|
|
9
9
|
const ROOM_LABEL_BG = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGAAAAA8CAYAAACZ1L+0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAYKADAAQAAAABAAAAPAAAAABU0H2EAAARRElEQVR4Ad2czY9cRZbFq1yFoQGDNCzwuAENohl54dkgdrNh34tZ8GciFi31nwEsmAEhhAWD1GMJCZgx5sMfUHN+J+NE3XfrZWWVcVVLHVLmuXG/74148V5m2bm/N8bR0dH+Bx988Po333zzbz///PONg4ODa+I9I9y/cuXKgV77h4eH+1KH3hP/yv7+vuBAsG+5UCIpCkMzDQ962Eu80Q1P/KmHT82v8IocZFL4pslDvL3fNARHoPI2wtbrV1jBIf9N8SEZ0UUP2wFHv2ocSc/2ouEz8PVooJXQ0/j10aNHoH2Idj4PHz4k1n29/k+5/u3ll1/+r7fffvtLzfGzd8ibjK6+9957f5ajf1XzH9y7d+8Xjf9FRs1SdvNBBg2SDQ1xh9ALH4yN0M2BNZrKwtFc9Fmkquuma5HJBzvLiIONBnx40B7QIzTdxCcNwj3dYlEoUmabAU+UFZDpxah22Ng2NjQXH0LrwccGwyEzXfWhWQwSYQHYuFevXj14/vnn37h79+7Nr7766gup/FX5PnAj33///f/46aef3vj444/vfPbZZz9IYGMcnDbkhEYQL001Hfsu775i+7j6LID6cDQWYo8mabGMxOr+e/ye3y7989p3/9jfvHnz2q1bt25oMb549913/3Lwzjvv/Mu3337775988smdzz///AcVQ+IecsAOp8OOHRpkiJniWQnrBJmwc7EF8atxBA2ihx/obf7Qq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+uE1sQWfeX3MBuyzx5B39P/fRcr4dcAT9p5bxl4zhIgNqgnlRkILKuf1654tIUCk2oLJYbQpr0ZqRrGt30C1tk4FnyQYccray31B3s9UQviG104IUGmZ8mH5v+3qF2w51nn332TzHCsI7KJzEVm6akEVuPhLWGhUeM0CAjvkHmxCM+uCYPD2R0f2Ilt7lB4tMGZ3i7qPqfe+65P6j3X1y5du3aZ3rSefrGjRsvkNxpI80AeTGC0NgGoakvuFYrtvDjD11okBF6m3yjdfze9eM7sbPQIC8sg8detlPdP7XCy8ASOh6IC534Qf126Au6Aq7S+0P9jOJ/f/jhh7dfeeWVN1C4c+cOv5zoxsQgKD7O/OgIT3OLgrrkLAMR9EuQYsXLlWO5ePNMJ25s7Fhv8EIraduDDOJI7kfh6FT98M6Ka/GrLbE0/131X79+/YVXX331+tNPP32b3nt1tGhXP/rooz/ruf9N/YzWQ/2e2c8Cfg7Wz8RC9WkeE8pj/rQltMRH/jXdsdreAEp04mg8u22zYhvZ9IPueLE4puMLfnjRKzKCbD4ZHv9oK/mwaPOlm/ukkbFwjKLj428j8t8DEEvN9xJoJuhsDI9lxOeHXr3zE8cGm7fpQMfNgR54ntXmYXzx1ltvbX64VUl4SH//66+/fl2/5ndLC/BHMV/Q6ypN06Bm3lgFaKMcEbj+bDHN88/curvewF4hjhNWasrwhy/0waIPjylyYjp49Ag++NhFhi7F+jeEFcc/H6w5TYbnxo2OoufXmNPcX+XWv4QLMo+taJkfeY4gvtRs/n8vzY/cssxB5CyKxi96/aB+/Y9+KfE/X3vttS8lI7e9/wfu514OAjYP0QAAAABJRU5ErkJggg==';
|
|
10
10
|
|
|
11
|
-
/* src/ModelRoomLabelPlugin/RoomLabelItem.svelte generated by Svelte v3.
|
|
11
|
+
/* src/ModelRoomLabelPlugin/RoomLabelItem.svelte generated by Svelte v3.50.1 */
|
|
12
12
|
|
|
13
13
|
function add_css$1(target) {
|
|
14
14
|
internal.append_styles(target, "svelte-877671", ".room-label-item.svelte-877671{position:absolute;font-size:0.41667rem;z-index:0;transform:none;cursor:pointer;pointer-events:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}.room-label-item__text.svelte-877671{position:absolute;left:0;top:-3.33333rem;transform:translate(-50%, 0);display:flex;justify-content:center;align-items:center;height:1.04167rem;min-width:1.66667rem;padding:0 0.3125rem;pointer-events:all;background-size:100% 100%;background-repeat:no-repeat;white-space:nowrap}.room-label-item__bar.svelte-877671{position:absolute;top:-2.29167rem;height:2.5rem;width:1px;background-image:linear-gradient(to bottom, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0))}.wide.svelte-877671{font-size:0.52083rem}");
|
|
@@ -108,7 +108,7 @@ class RoomLabelItem extends internal.SvelteComponent {
|
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
-
/* src/ModelRoomLabelPlugin/RoomLabelItems.svelte generated by Svelte v3.
|
|
111
|
+
/* src/ModelRoomLabelPlugin/RoomLabelItems.svelte generated by Svelte v3.50.1 */
|
|
112
112
|
|
|
113
113
|
const { Map: Map_1 } = internal.globals;
|
|
114
114
|
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import * as THREE from 'three';
|
|
2
2
|
import type { Five } from "@realsee/five";
|
|
3
|
+
declare const Vector3: typeof THREE.Vector3;
|
|
3
4
|
/**
|
|
4
5
|
* 碰撞检测可见性
|
|
5
6
|
* */
|
|
6
7
|
export declare const isImpacted: (five: Five, sourceVector: THREE.Vector3, targetVector: THREE.Vector3, distance: number) => boolean;
|
|
8
|
+
export {};
|