+
@@ -543,30 +544,32 @@ export default {
},
async mounted() {
await isAMRT()
- const param = {
- appkey: 'aveMPyNWzDJm',
- appsecret: 'rXmhoLAiOPNKzbl7g2qxCV8tFwRdYuZM'
- }
- const viewer = new AMRT.Viewer('container', param)
+ // const param = {
+ // appkey: 'aveMPyNWzDJm',
+ // appsecret: 'rXmhoLAiOPNKzbl7g2qxCV8tFwRdYuZM'
+ // }
+ const viewer = new AMRT.Viewer('container', {offline: true})
+ viewer.sceneManager.setBackground('http://10.100.72.10:8900/docs/img/bg.jpg')
+
let num = 0
let num2 = 0
let num3 = 0
let modelArr = [
- '../../models/01-01-01/',
- '../../models/01-01-02/',
- '../../models/01-01-03/',
- '../../models/01-01-04/',
- '../../models/01-01-05/',
- '../../models/01-02-01/',
- '../../models/01-02-02/',
- '../../models/01-02-03/',
- '../../models/01-02-04/',
- '../../models/01-02-05/',
- '../../models/01-02-06/',
- '../../models/01-02-07/',
- '../../models/01-03/',
- '../../models/01-04/',
- '../../models/01changfang/',
+ 'http://10.100.72.10:8900/docs/01-01-01/',
+ 'http://10.100.72.10:8900/docs/01-01-02/',
+ 'http://10.100.72.10:8900/docs/01-01-03/',
+ 'http://10.100.72.10:8900/docs/01-01-04/',
+ 'http://10.100.72.10:8900/docs/01-01-05/',
+ 'http://10.100.72.10:8900/docs/01-02-01/',
+ 'http://10.100.72.10:8900/docs/01-02-02/',
+ 'http://10.100.72.10:8900/docs/01-02-03/',
+ 'http://10.100.72.10:8900/docs/01-02-04/',
+ 'http://10.100.72.10:8900/docs/01-02-05/',
+ 'http://10.100.72.10:8900/docs/01-02-06/',
+ 'http://10.100.72.10:8900/docs/01-02-07/',
+ 'http://10.100.72.10:8900/docs/01-03/',
+ 'http://10.100.72.10:8900/docs/01-04/',
+ 'http://10.100.72.10:8900/docs/01changfang/',
// '1733002676922355712',
@@ -623,40 +626,40 @@ export default {
// '1733052268669964288',
]
let modelArr2 = [
- '../../models/02-01/',
- '../../models/02-01-01/',
- '../../models/02-01-02-01/',
- '../../models/02-01-02-02/',
- '../../models/02-01-03-01/',
- '../../models/02-01-03-02/',
- '../../models/02-02/',
- '../../models/02-02-01/',
- '../../models/02-02-02/',
- '../../models/02-03/',
- '../../models/02-03-1/',
- '../../models/02-04/',
- '../../models/02-04-01-01/',
- '../../models/02-04-01-02/',
- '../../models/02-04-02/',
- '../../models/02-05/',
- '../../models/02changfang/',
+ 'http://10.100.72.10:8900/docs/02-01/',
+ 'http://10.100.72.10:8900/docs/02-01-01/',
+ 'http://10.100.72.10:8900/docs/02-01-02-01/',
+ 'http://10.100.72.10:8900/docs/02-01-02-02/',
+ 'http://10.100.72.10:8900/docs/02-01-03-01/',
+ 'http://10.100.72.10:8900/docs/02-01-03-02/',
+ 'http://10.100.72.10:8900/docs/02-02/',
+ 'http://10.100.72.10:8900/docs/02-02-01/',
+ 'http://10.100.72.10:8900/docs/02-02-02/',
+ 'http://10.100.72.10:8900/docs/02-03/',
+ 'http://10.100.72.10:8900/docs/02-03-1/',
+ 'http://10.100.72.10:8900/docs/02-04/',
+ 'http://10.100.72.10:8900/docs/02-04-01-01/',
+ 'http://10.100.72.10:8900/docs/02-04-01-02/',
+ 'http://10.100.72.10:8900/docs/02-04-02/',
+ 'http://10.100.72.10:8900/docs/02-05/',
+ 'http://10.100.72.10:8900/docs/02changfang/',
]
let modelArr3 = [
- '../../models/03-01-01/',
- '../../models/03-01-02/',
- '../../models/03-02-01/',
- '../../models/03-02-02/',
- '../../models/03-02-03/',
- '../../models/03-02-04/',
- '../../models/03-02-05/',
- '../../models/03-03/',
- '../../models/03-04/',
- '../../models/03-05/',
- '../../models/03-06/',
- '../../models/03-07/',
- '../../models/03-08/',
- '../../models/03-09/',
- '../../models/03-10/',
+ 'http://10.100.72.10:8900/docs/03-01-01/',
+ 'http://10.100.72.10:8900/docs/03-01-02/',
+ 'http://10.100.72.10:8900/docs/03-02-01/',
+ 'http://10.100.72.10:8900/docs/03-02-02/',
+ 'http://10.100.72.10:8900/docs/03-02-03/',
+ 'http://10.100.72.10:8900/docs/03-02-04/',
+ 'http://10.100.72.10:8900/docs/03-02-05/',
+ 'http://10.100.72.10:8900/docs/03-03/',
+ 'http://10.100.72.10:8900/docs/03-04/',
+ 'http://10.100.72.10:8900/docs/03-05/',
+ 'http://10.100.72.10:8900/docs/03-06/',
+ 'http://10.100.72.10:8900/docs/03-07/',
+ 'http://10.100.72.10:8900/docs/03-08/',
+ 'http://10.100.72.10:8900/docs/03-09/',
+ 'http://10.100.72.10:8900/docs/03-10/',
]
modelArr.forEach(e => {
viewer.loadModel(e, {
@@ -689,27 +692,18 @@ export default {
alert('加载完成');
}
m.on('click', function () {
- console.log(m)
- console.log(e)
- console.log(m.getObjectById)
})
}
})
})
}
m.on('click', function () {
- console.log(m)
- console.log(e)
- console.log(m.getObjectById)
})
}
})
})
}
m.on('click', function () {
- console.log(m)
- console.log(e)
- console.log(m.getObjectById)
})
}
})
@@ -724,10 +718,14 @@ export default {
// viewer.operator.translucenceOthers(object.object)
// }
// })
- viewer.controls.setTarget(26.3, -19.8, -82)
- viewer.controls.setPosition(31, 1721, 584)
+ viewer.controls.setTarget(213, -34, -40)
+ viewer.controls.setPosition(188, 931, 1443)
viewer.operator.enabled = true
+ setInterval(() => {
+ console.log(viewer.controls.getView())
+
+ }, 1000)
// 灯光
viewer.sceneManager.setLightness(1)
@@ -758,6 +756,7 @@ export default {
};