|
@@ -1470,11 +1470,20 @@ Potree.updateVisibility = function(pointclouds, camera, areaSize){
|
|
|
|
|
|
let maxNodesLoading = Common.getBestCount('unloadedGeometry', viewer.lastFrameChanged?1:3, 6, 4, 15 /* , true */ )//dur在iphoneX中静止有7,pc是2 //!lastFrameChanged静止时加速下载
|
|
|
//THREE.Math.clamp(Math.round(9 - dur), 1, 6 )
|
|
|
-
|
|
|
+ //console.log('maxNodesLoading',)
|
|
|
//主要在手机端有效果。不改之前在展示的点云较多时前进会卡。
|
|
|
for (let i = 0; i < Math.min(maxNodesLoading, unloadedGeometry.length); i++) {
|
|
|
unloadedGeometry[i].node.load(unloadedGeometry[i].pointcloud.pcoGeometry);
|
|
|
}
|
|
|
+ if(!Potree.pointsLoading){
|
|
|
+ Potree.pointsLoading = true
|
|
|
+ //console.log('startLoad')
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ if(Potree.pointsLoading){
|
|
|
+ Potree.pointsLoading = false
|
|
|
+ //console.log('load done!')
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
|