|
@@ -75216,7 +75216,13 @@ void main()
|
|
|
viewer.images360.addPanoData(data, dataset.id );
|
|
|
panosLoaded ++;
|
|
|
if(panosLoaded == datasetLength){
|
|
|
- panosLoadDone();
|
|
|
+
|
|
|
+ Potree.loadImgVersion((e)=>{
|
|
|
+ Potree.settings.panoVersion = e.imgVersion;//全景图被替换后
|
|
|
+ panosLoadDone();
|
|
|
+ });
|
|
|
+
|
|
|
+
|
|
|
}
|
|
|
});
|
|
|
});
|
|
@@ -93718,7 +93724,7 @@ void main()
|
|
|
if(e.reason == 'screenshot' || e.visible){
|
|
|
this.label && (this.label.visible = e.visible);//截图时隐藏下
|
|
|
}
|
|
|
- //this.label2 && Potree.Utils.updateVisible(this.label2, 'panoVisi', e.visible)
|
|
|
+ this.label2 && Potree.Utils.updateVisible(this.label2, 'panoVisi', e.visible);
|
|
|
});
|
|
|
/*
|
|
|
漫游点可见性:旧
|
|
@@ -94204,11 +94210,11 @@ void main()
|
|
|
//let s = 0.25
|
|
|
//this.label2.scale.set(s,s,s)
|
|
|
Potree.Utils.updateVisible(this.label2, 'notDisplay', false);
|
|
|
- //Potree.Utils.updateVisible(this.label2, 'panoVisi', this.visible)
|
|
|
+ Potree.Utils.updateVisible(this.label2, 'panoVisi', this.visible);
|
|
|
|
|
|
|
|
|
|
|
|
- Potree.Utils.setObjectLayers(this.label2, 'bothMapAndScene');
|
|
|
+ //Potree.Utils.setObjectLayers(this.label2, 'bothMapAndScene')
|
|
|
}
|
|
|
|
|
|
removeTextLabel(){
|
|
@@ -96085,10 +96091,29 @@ void main()
|
|
|
d = this.getTiles(d, sceneCode, useV4url, o.pano.pointcloud);
|
|
|
g = "&";
|
|
|
}
|
|
|
-
|
|
|
- d += g + 'time='+o.pano.pointcloud.timeStamp; //加后缀
|
|
|
+ //Potree.settings.panoVersion = 4
|
|
|
+ d += g + (Potree.settings.panoVersion ? 'version='+Potree.settings.panoVersion : 'time='+o.pano.pointcloud.timeStamp ); //加后缀
|
|
|
|
|
|
return d;
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ /* 4dkk
|
|
|
+ getViewImagesURL(url) {
|
|
|
+ if (url.indexOf('&_=') !== -1) {
|
|
|
+ return url
|
|
|
+ }
|
|
|
+ let version = url.indexOf('/panorama/') !== -1 ? this.linkVersion : this.imageVersion
|
|
|
+ if (url.indexOf('?') !== -1) {
|
|
|
+ return this.$app.config.resource + `scene_view_data/${this.num}/images/${url}&_=${version}`
|
|
|
+ }
|
|
|
+ return this.$app.config.resource + `scene_view_data/${this.num}/images/${url}?_=${version}`
|
|
|
+ }
|
|
|
+ /**
|
|
|
+ */
|
|
|
+
|
|
|
}
|
|
|
}();
|
|
|
|
|
@@ -101636,7 +101661,7 @@ void main()
|
|
|
|
|
|
if(this.pickedFace) {
|
|
|
this.viewer.setView(this.pickedFace);
|
|
|
- }
|
|
|
+ }
|
|
|
};
|
|
|
|
|
|
this.viewer.renderer.domElement.addEventListener('mousedown', onMouseDown, false);
|
|
@@ -111332,11 +111357,11 @@ ENDSEC
|
|
|
}) */
|
|
|
|
|
|
|
|
|
- viewer.images360.panos.forEach(pano=>{
|
|
|
- pano.addLabel2();
|
|
|
- Potree.Utils.updateVisible(pano.label2, 'notDisplay', true);
|
|
|
- pano.dispatchEvent({type:'changeMarkerTex',name:'ring'});
|
|
|
- });
|
|
|
+ /* viewer.images360.panos.forEach(pano=>{
|
|
|
+ pano.addLabel2()
|
|
|
+ Potree.Utils.updateVisible(pano.label2, 'notDisplay', true)
|
|
|
+ pano.dispatchEvent({type:'changeMarkerTex',name:'ring'})
|
|
|
+ }) */
|
|
|
|
|
|
//材质
|
|
|
this.statesBefore = {
|
|
@@ -111463,10 +111488,10 @@ ENDSEC
|
|
|
Potree.Utils.updateVisible(pano.mapMarker, 'split4Screens', true)
|
|
|
}) */
|
|
|
|
|
|
- viewer.images360.panos.forEach(pano=>{
|
|
|
- Potree.Utils.updateVisible(pano.label2, 'notDisplay', false );
|
|
|
- pano.dispatchEvent({type:'changeMarkerTex',name:'default'});
|
|
|
- });
|
|
|
+ /* viewer.images360.panos.forEach(pano=>{
|
|
|
+ Potree.Utils.updateVisible(pano.label2, 'notDisplay', false )
|
|
|
+ pano.dispatchEvent({type:'changeMarkerTex',name:'default'})
|
|
|
+ }) */
|
|
|
|
|
|
mapViewport.noPointcloud = true;
|
|
|
{
|
|
@@ -113052,7 +113077,7 @@ ENDSEC
|
|
|
|
|
|
viewer.images360.panos.forEach(pano=>{
|
|
|
Potree.Utils.setObjectLayers(pano.marker, 'siteModelMapUnvisi' );
|
|
|
- Potree.Utils.setObjectLayers(pano.label2, 'bothMapAndScene');
|
|
|
+ //Potree.Utils.setObjectLayers(pano.label2, 'bothMapAndScene')
|
|
|
});
|
|
|
mapViewport.layersAdd('siteModeOnlyMapVisi'); //只有mapViewport能看到marker
|
|
|
|
|
@@ -113080,7 +113105,7 @@ ENDSEC
|
|
|
|
|
|
viewer.images360.panos.forEach(pano=>{
|
|
|
Potree.Utils.setObjectLayers(pano.marker, 'sceneObjects' );
|
|
|
- Potree.Utils.setObjectLayers(pano.label2, 'bothMapAndScene');
|
|
|
+ //Potree.Utils.setObjectLayers(pano.label2, 'bothMapAndScene')
|
|
|
});
|
|
|
|
|
|
mapViewport.layersRemove('siteModeOnlyMapVisi');
|
|
@@ -147899,7 +147924,12 @@ ENDSEC
|
|
|
|
|
|
if(!ifForce) ifForce = tileset.nextForceUpdate;
|
|
|
tileset.nextForceUpdate = false;
|
|
|
+ if(tileset.needRenderNext){
|
|
|
+ viewer.dispatchEvent('content_changed');
|
|
|
+ }
|
|
|
|
|
|
+ tileset.needRenderNext = ifForce;
|
|
|
+
|
|
|
if (tileset && (timer >= UPDATE_INTERVAL || ifForce)) {
|
|
|
if (!lastRootTransform.equals(root.matrixWorld)) {
|
|
|
timer = 0;
|
|
@@ -155831,6 +155861,7 @@ ENDSEC
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
+
|
|
|
|
|
|
|
|
|
}
|
|
@@ -157035,6 +157066,21 @@ ENDSEC
|
|
|
|
|
|
|
|
|
|
|
|
+ async function loadImgVersion( callback){
|
|
|
+ var path;
|
|
|
+ //let query = `?datasetId=${datasetId}` //`?lat=${center.lat}&lon=${center.lon}&radius=200000`
|
|
|
+ /* if(Potree.fileServer){
|
|
|
+ path = `/laser/filter/${Potree.settings.number}/query`
|
|
|
+ }else{ */
|
|
|
+ path = `${Potree.settings.urls.prefix}/init/getSceneNumVersion/${Potree.settings.number}`;
|
|
|
+
|
|
|
+ //}
|
|
|
+ return loadFile(path, {}, callback)
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
//site_model
|
|
|
/* {
|
|
|
"area": 2503.30551910935,
|
|
@@ -157371,6 +157417,7 @@ ENDSEC
|
|
|
exports.framenumber = framenumber;
|
|
|
exports.loadDatasets = loadDatasets;
|
|
|
exports.loadFile = loadFile;
|
|
|
+ exports.loadImgVersion = loadImgVersion;
|
|
|
exports.loadMapEntity = loadMapEntity;
|
|
|
exports.loadPanos = loadPanos;
|
|
|
exports.loadPanosInfo = loadPanosInfo;
|