|
@@ -21576,7 +21576,7 @@
|
|
|
*/
|
|
|
//=======================================================================
|
|
|
|
|
|
- function panoEditStart(dom, number, fileServer) {
|
|
|
+ function panoEditStart(dom, number, EditCloudsArgs) {
|
|
|
Potree.settings.editType = 'pano';
|
|
|
Potree.settings.number = number;
|
|
|
Potree.settings.unableNavigate = true;
|
|
@@ -21598,6 +21598,15 @@
|
|
|
});
|
|
|
Potree.settings.sizeFitToLevel = true;
|
|
|
}
|
|
|
+ EditCloudsArgs.forEach((e, i) => {
|
|
|
+ //加载点云和漫游点
|
|
|
+ if (e.datasetId == void 0) {
|
|
|
+ console.error('没有datasetId '); // 看看和看见没有
|
|
|
+ e.datasetId = i; //经常没有datasetId所以自己加
|
|
|
+ }
|
|
|
+ Potree.settings.datasetsPanos[e.datasetId] = null;
|
|
|
+ Potree.loadPanosDone(e.datasetId, e.clouds);
|
|
|
+ });
|
|
|
var pointcloudLoadDone = function pointcloudLoadDone() {
|
|
|
//所有点云cloud.js加载完毕后
|
|
|
|
|
@@ -21933,6 +21942,7 @@
|
|
|
//model.lastMatrixWorld = model.matrixWorld.clone()
|
|
|
model.lastMatrixWorld = new Matrix4();
|
|
|
MergeEditor.modelTransformCallback(model, true);
|
|
|
+ prop.scale != void 0 && model.isPointcloud && model.changePointSize();
|
|
|
done(model); // 先发送成功,因为2d界面会随机执行changePosition等初始化,然后这边再将模型移到中心地面上
|
|
|
|
|
|
if (prop.isFirstLoad) {
|
|
@@ -76183,12 +76193,13 @@
|
|
|
});
|
|
|
};
|
|
|
var scroll = e => {
|
|
|
+ var _viewer$inputHandler$, _viewer$inputHandler$2, _viewer$modules$Merge;
|
|
|
if (!this.enabled) return;
|
|
|
var resolvedRadius = this.currentViewport.view.radius + this.radiusDelta;
|
|
|
- var I = viewer.inputHandler.intersect;
|
|
|
+ var model = ((_viewer$inputHandler$ = viewer.inputHandler.intersect) === null || _viewer$inputHandler$ === void 0 ? void 0 : _viewer$inputHandler$.model) || ((_viewer$inputHandler$2 = viewer.inputHandler.intersect) === null || _viewer$inputHandler$2 === void 0 ? void 0 : _viewer$inputHandler$2.pointcloud) || ((_viewer$modules$Merge = viewer.modules.MergeEditor) === null || _viewer$modules$Merge === void 0 ? void 0 : _viewer$modules$Merge.selected);
|
|
|
var min = 0.1;
|
|
|
- if (I) {
|
|
|
- min *= (I.model || I.pointcloud).scale.x;
|
|
|
+ if (model) {
|
|
|
+ min *= model.scale.x;
|
|
|
}
|
|
|
if (resolvedRadius < min && e.delta > 0) return; //防止缩放太小,导致很慢
|
|
|
this.radiusDelta += -e.delta * resolvedRadius * 0.1;
|