123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215 |
- //xzw add
- import browser from './utils/browser'
- const config = {//配置参数 不可修改
- displayMode:{
- showPointCloud:{
- atPano:{
- showPoint : true,
- showSkybox: false,
- pointUsePanoTex : false
-
- },
- transition:{
- showPoint: true,
- showSkybox: false,
- pointUsePanoTex: false
- },
- canLeavePano: true //是否能离开pano位置
- },
- showPanos:{
- atPano:{
- showPoint : false,
- showSkybox: true,
- pointUsePanoTex : false
- },
- transition:{
- showPoint: true,
- showSkybox: true,
- pointUsePanoTex: true //是否使用全景贴图
- },
- canLeavePano: false
- },
-
- showBoth:{
- atPano:{
- showPoint : true,
- showSkybox: true,
- pointUsePanoTex : false //?
- },
- transition:{
- showPoint: true,
- showSkybox: true,
- pointUsePanoTex: true
- },
- canLeavePano: true //是否能离开pano位置 离开后自动变为showPointCloud
- },
- //test:
- pointUsePanoTex:{ //---静止时调点云
- atPano:{
- showPoint : true,
- showSkybox: false,
- pointUsePanoTex : true
- },
- transition:{
- showPoint: true,
- showSkybox: true,
- pointUsePanoTex: true //是否使用全景贴图
- },
- canLeavePano: false
- },
- },
-
-
-
- urls:{
- //localTextures:'../resources/textures/',
- prefix: 'laser-oss.4dkankan.com',//oss
- prefix2: 'testlaser.4dkankan.com'
- },
-
- transitionsTime:{
- flySpeed : 200,//400, // 毫秒/米
- panoToPano: 1000,//2000,
- flyIn:1000,
- flyOut:1000,
- }
- ,
- view:{
- fov:50, //navvis:50
- },
-
- pointDensity:{
- low:{//highPerformance
- maxLevel: 4, //最小为0
- pointBudget :1*1000*1000,
- },
- middle:{//balanced
- maxLevel: 5,
- pointBudget:4*1000*1000,
- },
- high:{//highQuality
- maxLevel: 8,
- pointBudget:8*1000*1000,
- }
- //minNodeSize?
- },
-
-
-
-
-
-
-
-
-
- measure:{
- lineColor:"#00c7b2",
- highLightColor:'#FFFFFF',//'#02e4cc', //hover时线条和mainLabel颜色
- backColor:'#333333',
- guideLineColor:"#FFFFFF",
- lineWidth: 4,
- labelOpacity:0.8,
- textColor: "#FFFFFF"
-
- },
- material:{//初始化
- pointSize:0.75,//0.4,
- minSize: 0.1,
- pointSizeType: 'ADAPTIVE'//
- //ADAPTIVE : 字会失真扭曲
- //'ATTENUATED' 往旁边看有缝隙、点在浮动
- //navvis的shader在哪里 为什么不会抖动
- }
- ,
-
-
- renderLayers:{//渲染层,方便分批渲染管理,替代scene的创建。数字不代表顺序。
-
- skybox: 1,
- pointcloud: 0,
- marker: 2,
- reticule: 3,
- measure:4,
- magnifier:5,
- volume:6,
- transformationTool:7,
- route:10,
- map:8,
- mapObjects:9,
- },
-
- tiling: {
- panoPreRenderRepeatDelay: 2500,
- panoPreRenderDelay: 500,
- preRenderTourPanos: browser.valueFromHash("tileprerender", 0),
- tilingFlagNames: ["usetiles", "tiles"],
- maxNavPanoQuality: browser.valueFromHash("maxtileq", null),
- maxZoomPanoQuality: browser.valueFromHash("maxztileq", null),
- overlayStyle: browser.valueFromHash("tileoverlay", 0),
- uploadIntervalDelay: browser.valueFromHash("tileupdelay", 10),
- initialIntervalDelay: browser.valueFromHash("itiledelay", 0),
- maxNonBaseUploadsPerFrame: browser.valueFromHash("maxnbtpf", 2),
- maxBaseUploadsPerFrame: browser.valueFromHash("maxbtpf", 6),
- customCompression: browser.valueFromHash("tilecustcomp", 0),
- mobileHighQualityOverride: !1,
- allowUltraHighResolution: !0
- },
- navigation: {
- panoScores: !1,
- mouseDirection: !0,
- filterStrictness: .75,
- angleFactor: -30,
- directionFactor: 10,
- distanceFactor: -1,
- optionalityFactor: 3
- },
- OrthoCameraLimit:{
- zoom:{min:0.001, max:100}, //如果camera缩太小,地图会因为数字边界问题而扭曲
- posBound:{
- min: {x:-1e5, y:-1e5,z:-1 / 0},
- max: {x:1e5, y:1e5, z:1 / 0 }
- }
- }
- ,
-
- }
- /* 显示模式:
- 1只显示点云: 滚轮为前进后退,方向键可以行走。进入漫游点时自动变为混合(这样全景可以弥补缝隙),过渡时只显示点云。
- 2只显示全景: 不能任意行走。 过渡时显示贴图材质非edl的点云(否则有折痕不贴合)。
- 3混合:都显示。 不能任意行走。过渡时显示贴图材质非edl的点云(因为只显示点云的话不太美,点云很碎,不细腻)
- */
-
- function getPrefix(){
- let u = window.location.href.split('//')
- let v = u[1].split('/');
- return v[0]
- }
- let settings = {//设置 可修改
- number: '', //场景序号
- isOfficial:false,
- displayMode:'',
- isTest :browser.urlHasValue('test'),
- prefix:getPrefix(),
- pointDensity: '',
- ifShowMarker:true,//显示漫游点
- floorplanType:null,//平面图类型 'default' | 'diy'
- floorplanEnable:false,
- cameraFar : 300, //相机最远范围 1-300
- limitFar: true, //是否使用setting的cameraFar来限制(如在点云裁剪时为false)
- showPanoMesh:false, //显示小球,
- dblToFocusPoint:false,//调试时如果需要双击飞向某个点云的点,就打开。此时不在漫游点的话单击将无法漫游。//因和单击漫游冲突
-
- unableNavigate : false//进入如裁剪界面时 禁止漫游
- }
- settings.isLocalhost = settings.prefix.includes('localhost')
-
- export {config, settings}
|